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
87ea7698
Commit
87ea7698
authored
Oct 06, 2020
by
Paul Gofman
Committed by
Alexandre Julliard
Oct 08, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Allocate TEB FLS data in LdrInitializeThunk().
Signed-off-by:
Paul Gofman
<
pgofman@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
767fa070
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
3 deletions
+5
-3
loader.c
dlls/kernel32/tests/loader.c
+1
-2
loader.c
dlls/ntdll/loader.c
+2
-0
ntdll_misc.h
dlls/ntdll/ntdll_misc.h
+1
-0
thread.c
dlls/ntdll/thread.c
+1
-1
No files found.
dlls/kernel32/tests/loader.c
View file @
87ea7698
...
@@ -2629,8 +2629,7 @@ todo_wine
...
@@ -2629,8 +2629,7 @@ todo_wine
SetLastError
(
0xdeadbeef
);
SetLastError
(
0xdeadbeef
);
value
=
pFlsGetValue
(
fls_index
);
value
=
pFlsGetValue
(
fls_index
);
ok
(
!
value
,
"FlsGetValue returned %p, expected NULL
\n
"
,
value
);
ok
(
!
value
,
"FlsGetValue returned %p, expected NULL
\n
"
,
value
);
todo_wine
ok
(
GetLastError
()
==
ERROR_SUCCESS
,
"FlsGetValue failed with error %u
\n
"
,
GetLastError
());
ok
(
GetLastError
()
==
ERROR_SUCCESS
,
"FlsGetValue failed with error %u
\n
"
,
GetLastError
());
ret
=
pFlsSetValue
(
fls_index
,
(
void
*
)
0x31415
);
ret
=
pFlsSetValue
(
fls_index
,
(
void
*
)
0x31415
);
ok
(
ret
,
"FlsSetValue failed
\n
"
);
ok
(
ret
,
"FlsSetValue failed
\n
"
);
fls_count
++
;
fls_count
++
;
...
...
dlls/ntdll/loader.c
View file @
87ea7698
...
@@ -3511,6 +3511,8 @@ void WINAPI LdrInitializeThunk( CONTEXT *context, ULONG_PTR unknown2, ULONG_PTR
...
@@ -3511,6 +3511,8 @@ void WINAPI LdrInitializeThunk( CONTEXT *context, ULONG_PTR unknown2, ULONG_PTR
InsertHeadList
(
&
tls_links
,
&
NtCurrentTeb
()
->
TlsLinks
);
InsertHeadList
(
&
tls_links
,
&
NtCurrentTeb
()
->
TlsLinks
);
RtlReleasePebLock
();
RtlReleasePebLock
();
NtCurrentTeb
()
->
FlsSlots
=
fls_alloc_data
();
if
(
!
attach_done
)
/* first time around */
if
(
!
attach_done
)
/* first time around */
{
{
attach_done
=
1
;
attach_done
=
1
;
...
...
dlls/ntdll/ntdll_misc.h
View file @
87ea7698
...
@@ -129,5 +129,6 @@ static inline void ascii_to_unicode( WCHAR *dst, const char *src, size_t len )
...
@@ -129,5 +129,6 @@ static inline void ascii_to_unicode( WCHAR *dst, const char *src, size_t len )
/* FLS data */
/* FLS data */
extern
void
init_global_fls_data
(
void
)
DECLSPEC_HIDDEN
;
extern
void
init_global_fls_data
(
void
)
DECLSPEC_HIDDEN
;
extern
TEB_FLS_DATA
*
fls_alloc_data
(
void
)
DECLSPEC_HIDDEN
;
#endif
#endif
dlls/ntdll/thread.c
View file @
87ea7698
...
@@ -294,7 +294,7 @@ static unsigned int fls_chunk_index_from_index( unsigned int index, unsigned int
...
@@ -294,7 +294,7 @@ static unsigned int fls_chunk_index_from_index( unsigned int index, unsigned int
return
chunk_index
;
return
chunk_index
;
}
}
static
TEB_FLS_DATA
*
fls_alloc_data
(
void
)
TEB_FLS_DATA
*
fls_alloc_data
(
void
)
{
{
TEB_FLS_DATA
*
fls
;
TEB_FLS_DATA
*
fls
;
...
...
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