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
b793e2e4
Commit
b793e2e4
authored
Feb 25, 2016
by
Piotr Caban
Committed by
Alexandre Julliard
Feb 25, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msvcp110: Add _Thrd_detach implementation.
Signed-off-by:
Piotr Caban
<
piotr@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
b57b9983
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
21 additions
and
5 deletions
+21
-5
msvcp110.spec
dlls/msvcp110/msvcp110.spec
+1
-1
msvcp120.spec
dlls/msvcp120/msvcp120.spec
+1
-1
msvcp120.c
dlls/msvcp120/tests/msvcp120.c
+13
-2
msvcp120_app.spec
dlls/msvcp120_app/msvcp120_app.spec
+1
-1
misc.c
dlls/msvcp90/misc.c
+5
-0
No files found.
dlls/msvcp110/msvcp110.spec
View file @
b793e2e4
...
...
@@ -3858,7 +3858,7 @@
@ stub _Thrd_abort
@ cdecl _Thrd_create(ptr ptr ptr)
@ cdecl _Thrd_current()
@
stub _Thrd_detach
@
cdecl _Thrd_detach(ptr)
@ cdecl _Thrd_equal(ptr ptr)
@ stub _Thrd_exit
@ cdecl _Thrd_join(ptr long)
...
...
dlls/msvcp120/msvcp120.spec
View file @
b793e2e4
...
...
@@ -3805,7 +3805,7 @@
@ stub _Thrd_abort
@ cdecl _Thrd_create(ptr ptr ptr)
@ cdecl _Thrd_current()
@
stub _Thrd_detach
@
cdecl _Thrd_detach(ptr)
@ cdecl _Thrd_equal(ptr ptr)
@ stub _Thrd_exit
@ cdecl _Thrd_join(ptr long)
...
...
dlls/msvcp120/tests/msvcp120.c
View file @
b793e2e4
...
...
@@ -203,6 +203,7 @@ static void (__cdecl *p__Thrd_sleep)(const xtime*);
static
_Thrd_t
(
__cdecl
*
p__Thrd_current
)(
void
);
static
int
(
__cdecl
*
p__Thrd_create
)(
_Thrd_t
*
,
_Thrd_start_t
,
void
*
);
static
int
(
__cdecl
*
p__Thrd_join
)(
_Thrd_t
,
int
*
);
static
int
(
__cdecl
*
p__Thrd_detach
)(
_Thrd_t
);
#ifdef __i386__
static
ULONGLONG
(
__cdecl
*
p_i386_Thrd_current
)(
void
);
...
...
@@ -486,6 +487,8 @@ static BOOL init(void)
"_Thrd_create"
);
SET
(
p__Thrd_join
,
"_Thrd_join"
);
SET
(
p__Thrd_detach
,
"_Thrd_detach"
);
SET
(
p__Mtx_init
,
"_Mtx_init"
);
...
...
@@ -1677,7 +1680,8 @@ static int __cdecl thrd_thread(void *arg)
{
_Thrd_t
*
thr
=
arg
;
*
thr
=
p__Thrd_current
();
if
(
thr
)
*
thr
=
p__Thrd_current
();
return
0x42
;
}
...
...
@@ -1759,7 +1763,14 @@ static void test_thrd(void)
ok
(
ta
.
id
==
tb
.
id
,
"expected %d, got %d
\n
"
,
ta
.
id
,
tb
.
id
);
ok
(
ta
.
hnd
!=
tb
.
hnd
,
"same handles, got %p
\n
"
,
ta
.
hnd
);
ok
(
r
==
0x42
,
"expected 0x42, got %d
\n
"
,
r
);
ok
(
!
CloseHandle
(
ta
.
hnd
),
"handle %p not closed
\n
"
,
ta
.
hnd
);
ret
=
p__Thrd_detach
(
ta
);
ok
(
ret
==
4
,
"_Thrd_detach should have failed with error 4, got %d
\n
"
,
ret
);
ret
=
p__Thrd_create
(
&
ta
,
thrd_thread
,
NULL
);
ok
(
!
ret
,
"failed to create thread, got %d
\n
"
,
ret
);
ret
=
p__Thrd_detach
(
ta
);
ok
(
!
ret
,
"_Thrd_detach failed, got %d
\n
"
,
ret
);
}
#define NUM_THREADS 10
...
...
dlls/msvcp120_app/msvcp120_app.spec
View file @
b793e2e4
...
...
@@ -3805,7 +3805,7 @@
@ stub _Thrd_abort
@ cdecl _Thrd_create(ptr ptr ptr) msvcp120._Thrd_create
@ cdecl _Thrd_current() msvcp120._Thrd_current
@
stub
_Thrd_detach
@
cdecl _Thrd_detach(ptr) msvcp120.
_Thrd_detach
@ cdecl _Thrd_equal(ptr ptr) msvcp120._Thrd_equal
@ stub _Thrd_exit
@ cdecl _Thrd_join(ptr long) msvcp120._Thrd_join
...
...
dlls/msvcp90/misc.c
View file @
b793e2e4
...
...
@@ -874,6 +874,11 @@ int __cdecl _Thrd_create(_Thrd_t *thr, _Thrd_start_t proc, void *arg)
return
ret
;
}
int
__cdecl
_Thrd_detach
(
_Thrd_t
thr
)
{
return
CloseHandle
(
thr
.
hnd
)
?
0
:
_THRD_ERROR
;
}
typedef
struct
{
const
vtable_ptr
*
vtable
;
...
...
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