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
b4b75634
Commit
b4b75634
authored
Mar 23, 2022
by
Eric Pouech
Committed by
Alexandre Julliard
Mar 23, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll/tests: Enable compilation with long types in rtlbitmap.c.
Signed-off-by:
Eric Pouech
<
eric.pouech@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
4eded62d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
11 deletions
+12
-11
rtlbitmap.c
dlls/ntdll/tests/rtlbitmap.c
+12
-11
No files found.
dlls/ntdll/tests/rtlbitmap.c
View file @
b4b75634
...
...
@@ -20,6 +20,7 @@
* We use function pointers here as some of the bitmap functions exist only
* in later versions of ntdll.
*/
#undef WINE_NO_LONG_TYPES
/* temporary for migration */
#include "ntdll_test.h"
...
...
@@ -501,7 +502,7 @@ static void test_RtlFindSetRuns(void)
/* Get first 2 */
ulCount
=
pRtlFindSetRuns
(
&
bm
,
runs
,
2
,
FALSE
);
ok
(
ulCount
==
2
,
"RtlFindClearRuns returned %d, expected 2
\n
"
,
ulCount
);
ok
(
ulCount
==
2
,
"RtlFindClearRuns returned %
l
d, expected 2
\n
"
,
ulCount
);
ok
(
runs
[
0
].
StartingIndex
==
7
||
runs
[
0
].
StartingIndex
==
101
,
"bad find
\n
"
);
ok
(
runs
[
1
].
StartingIndex
==
7
||
runs
[
1
].
StartingIndex
==
101
,
"bad find
\n
"
);
ok
(
runs
[
0
].
NumberOfBits
+
runs
[
1
].
NumberOfBits
==
19
+
3
,
"bad size
\n
"
);
...
...
@@ -511,7 +512,7 @@ static void test_RtlFindSetRuns(void)
/* Get longest 3 */
memset
(
runs
,
0
,
sizeof
(
runs
));
ulCount
=
pRtlFindSetRuns
(
&
bm
,
runs
,
2
,
TRUE
);
ok
(
ulCount
==
2
,
"RtlFindClearRuns returned %d, expected 2
\n
"
,
ulCount
);
ok
(
ulCount
==
2
,
"RtlFindClearRuns returned %
l
d, expected 2
\n
"
,
ulCount
);
ok
(
runs
[
0
].
StartingIndex
==
7
||
runs
[
0
].
StartingIndex
==
1877
,
"bad find
\n
"
);
ok
(
runs
[
1
].
StartingIndex
==
7
||
runs
[
1
].
StartingIndex
==
1877
,
"bad find
\n
"
);
ok
(
runs
[
0
].
NumberOfBits
+
runs
[
1
].
NumberOfBits
==
33
+
19
,
"bad size
\n
"
);
...
...
@@ -521,7 +522,7 @@ static void test_RtlFindSetRuns(void)
/* Get all 3 */
memset
(
runs
,
0
,
sizeof
(
runs
));
ulCount
=
pRtlFindSetRuns
(
&
bm
,
runs
,
3
,
TRUE
);
ok
(
ulCount
==
3
,
"RtlFindClearRuns returned %d, expected 3
\n
"
,
ulCount
);
ok
(
ulCount
==
3
,
"RtlFindClearRuns returned %
l
d, expected 3
\n
"
,
ulCount
);
ok
(
runs
[
0
].
StartingIndex
==
7
||
runs
[
0
].
StartingIndex
==
101
||
runs
[
0
].
StartingIndex
==
1877
,
"bad find
\n
"
);
ok
(
runs
[
1
].
StartingIndex
==
7
||
runs
[
1
].
StartingIndex
==
101
||
...
...
@@ -539,7 +540,7 @@ static void test_RtlFindSetRuns(void)
ULONG
ulStart
=
0
;
ulCount
=
pRtlFindLongestRunSet
(
&
bm
,
&
ulStart
);
ok
(
ulCount
==
33
&&
ulStart
==
1877
,
"didn't find longest %
d %
d
\n
"
,
ulCount
,
ulStart
);
ok
(
ulCount
==
33
&&
ulStart
==
1877
,
"didn't find longest %
ld %l
d
\n
"
,
ulCount
,
ulStart
);
memset
(
buff
,
0
,
sizeof
(
buff
));
ulCount
=
pRtlFindLongestRunSet
(
&
bm
,
&
ulStart
);
...
...
@@ -578,7 +579,7 @@ static void test_RtlFindClearRuns(void)
/* Get first 2 */
ulCount
=
pRtlFindClearRuns
(
&
bm
,
runs
,
2
,
FALSE
);
ok
(
ulCount
==
2
,
"RtlFindClearRuns returned %d, expected 2
\n
"
,
ulCount
);
ok
(
ulCount
==
2
,
"RtlFindClearRuns returned %
l
d, expected 2
\n
"
,
ulCount
);
ok
(
runs
[
0
].
StartingIndex
==
7
||
runs
[
0
].
StartingIndex
==
101
,
"bad find
\n
"
);
ok
(
runs
[
1
].
StartingIndex
==
7
||
runs
[
1
].
StartingIndex
==
101
,
"bad find
\n
"
);
ok
(
runs
[
0
].
NumberOfBits
+
runs
[
1
].
NumberOfBits
==
19
+
3
,
"bad size
\n
"
);
...
...
@@ -588,7 +589,7 @@ static void test_RtlFindClearRuns(void)
/* Get longest 3 */
memset
(
runs
,
0
,
sizeof
(
runs
));
ulCount
=
pRtlFindClearRuns
(
&
bm
,
runs
,
2
,
TRUE
);
ok
(
ulCount
==
2
,
"RtlFindClearRuns returned %d, expected 2
\n
"
,
ulCount
);
ok
(
ulCount
==
2
,
"RtlFindClearRuns returned %
l
d, expected 2
\n
"
,
ulCount
);
ok
(
runs
[
0
].
StartingIndex
==
7
||
runs
[
0
].
StartingIndex
==
1877
,
"bad find
\n
"
);
ok
(
runs
[
1
].
StartingIndex
==
7
||
runs
[
1
].
StartingIndex
==
1877
,
"bad find
\n
"
);
ok
(
runs
[
0
].
NumberOfBits
+
runs
[
1
].
NumberOfBits
==
33
+
19
,
"bad size
\n
"
);
...
...
@@ -598,7 +599,7 @@ static void test_RtlFindClearRuns(void)
/* Get all 3 */
memset
(
runs
,
0
,
sizeof
(
runs
));
ulCount
=
pRtlFindClearRuns
(
&
bm
,
runs
,
3
,
TRUE
);
ok
(
ulCount
==
3
,
"RtlFindClearRuns returned %d, expected 3
\n
"
,
ulCount
);
ok
(
ulCount
==
3
,
"RtlFindClearRuns returned %
l
d, expected 3
\n
"
,
ulCount
);
ok
(
runs
[
0
].
StartingIndex
==
7
||
runs
[
0
].
StartingIndex
==
101
||
runs
[
0
].
StartingIndex
==
1877
,
"bad find
\n
"
);
ok
(
runs
[
1
].
StartingIndex
==
7
||
runs
[
1
].
StartingIndex
==
101
||
...
...
@@ -635,8 +636,8 @@ static void test_RtlFindNextForwardRunSet(void)
pRtlInitializeBitMap
(
&
bm
,
mask
,
62
);
ulCount
=
pRtlFindNextForwardRunSet
(
&
bm
,
ulStart
,
&
lpPos
);
ok
(
ulCount
==
6
,
"Invalid length of found set run: %d, expected 6
\n
"
,
ulCount
);
ok
(
lpPos
==
56
,
"Invalid position of found set run: %d, expected 56
\n
"
,
lpPos
);
ok
(
ulCount
==
6
,
"Invalid length of found set run: %
l
d, expected 6
\n
"
,
ulCount
);
ok
(
lpPos
==
56
,
"Invalid position of found set run: %
l
d, expected 56
\n
"
,
lpPos
);
}
static
void
test_RtlFindNextForwardRunClear
(
void
)
...
...
@@ -649,8 +650,8 @@ static void test_RtlFindNextForwardRunClear(void)
pRtlInitializeBitMap
(
&
bm
,
mask
,
62
);
ulCount
=
pRtlFindNextForwardRunClear
(
&
bm
,
ulStart
,
&
lpPos
);
ok
(
ulCount
==
6
,
"Invalid length of found clear run: %d, expected 6
\n
"
,
ulCount
);
ok
(
lpPos
==
56
,
"Invalid position of found clear run: %d, expected 56
\n
"
,
lpPos
);
ok
(
ulCount
==
6
,
"Invalid length of found clear run: %
l
d, expected 6
\n
"
,
ulCount
);
ok
(
lpPos
==
56
,
"Invalid position of found clear run: %
l
d, expected 56
\n
"
,
lpPos
);
}
#endif
...
...
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