Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
935eed8e
Commit
935eed8e
authored
Oct 05, 2018
by
Zebediah Figura
Committed by
Alexandre Julliard
Oct 09, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rpcrt4/tests: Add some tests for nesting arrays and pointers.
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
6f971037
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
0 deletions
+17
-0
server.c
dlls/rpcrt4/tests/server.c
+14
-0
server.idl
dlls/rpcrt4/tests/server.idl
+3
-0
No files found.
dlls/rpcrt4/tests/server.c
View file @
935eed8e
...
...
@@ -861,6 +861,16 @@ void __cdecl s_ip_test(ipu_t *a)
ok
(
hr
==
S_OK
,
"got %#x
\n
"
,
hr
);
}
int
__cdecl
s_sum_ptr_array
(
int
*
a
[
2
])
{
return
*
a
[
0
]
+
*
a
[
1
];
}
int
__cdecl
s_sum_array_ptr
(
int
(
*
a
)[
2
])
{
return
(
*
a
)[
0
]
+
(
*
a
)[
1
];
}
static
void
make_cmdline
(
char
buffer
[
MAX_PATH
],
const
char
*
test
)
{
...
...
@@ -1388,6 +1398,7 @@ array_tests(void)
pints_t
api
[
5
];
numbers_struct_t
*
ns
;
refpint_t
rpi
[
5
];
int
i0
=
1
,
i1
=
2
,
*
ptr_array
[
2
]
=
{
&
i0
,
&
i1
},
array
[
2
]
=
{
3
,
4
};
if
(
!
old_windows_version
)
{
...
...
@@ -1518,6 +1529,9 @@ array_tests(void)
pi
[
4
]
=
-
4
;
rpi
[
4
]
=
&
pi
[
4
];
ok
(
sum_complex_array
(
5
,
rpi
)
==
1
,
"RPC sum_complex_array
\n
"
);
HeapFree
(
GetProcessHeap
(),
0
,
pi
);
ok
(
sum_ptr_array
(
ptr_array
)
==
3
,
"RPC sum_ptr_array
\n
"
);
ok
(
sum_array_ptr
(
&
array
)
==
7
,
"RPC sum_array_ptr
\n
"
);
}
void
__cdecl
s_authinfo_test
(
unsigned
int
protseq
,
int
secure
)
...
...
dlls/rpcrt4/tests/server.idl
View file @
935eed8e
...
...
@@ -393,4 +393,7 @@ cpp_quote("#endif")
}
ipu_t
;
void
ip_test
(
[
in
]
ipu_t
*
a
)
;
int
sum_ptr_array
(
[
in
]
int
*
a
[
2
]
)
;
int
sum_array_ptr
(
[
in
]
int
(
*
a
)
[
2
]
)
;
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment