Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
bf174815
Commit
bf174815
authored
Apr 25, 2019
by
Nikolay Sivov
Committed by
Alexandre Julliard
Apr 25, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32/tests: Add a test for critical section DebugInfo initial value.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
4385a3ec
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
0 deletions
+21
-0
sync.c
dlls/kernel32/tests/sync.c
+21
-0
No files found.
dlls/kernel32/tests/sync.c
View file @
bf174815
...
...
@@ -2636,6 +2636,26 @@ static void test_apc_deadlock(void)
CloseHandle
(
pi
.
hProcess
);
}
static
void
test_crit_section
(
void
)
{
CRITICAL_SECTION
cs
;
BOOL
ret
;
/* Win8+ does not initialize debug info, one has to use RTL_CRITICAL_SECTION_FLAG_FORCE_DEBUG_INFO
to override that. */
memset
(
&
cs
,
0
,
sizeof
(
cs
));
InitializeCriticalSection
(
&
cs
);
ok
(
cs
.
DebugInfo
!=
NULL
,
"Unexpected debug info pointer %p.
\n
"
,
cs
.
DebugInfo
);
DeleteCriticalSection
(
&
cs
);
memset
(
&
cs
,
0
,
sizeof
(
cs
));
ret
=
InitializeCriticalSectionEx
(
&
cs
,
0
,
CRITICAL_SECTION_NO_DEBUG_INFO
);
ok
(
ret
,
"Failed to initialize critical section.
\n
"
);
todo_wine
ok
(
cs
.
DebugInfo
==
(
void
*
)(
ULONG_PTR
)
-
1
,
"Unexpected debug info pointer %p.
\n
"
,
cs
.
DebugInfo
);
DeleteCriticalSection
(
&
cs
);
}
START_TEST
(
sync
)
{
char
**
argv
;
...
...
@@ -2694,4 +2714,5 @@ START_TEST(sync)
test_srwlock_example
();
test_alertable_wait
();
test_apc_deadlock
();
test_crit_section
();
}
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