Commit 616415a6 authored by Alexandre Julliard's avatar Alexandre Julliard

ntdll: Store the debug info for the initial thread next to the PEB.

parent 789c1db1
......@@ -294,6 +294,5 @@ void dbg_init(void)
{
setbuf( stdout, NULL );
setbuf( stderr, NULL );
ntdll_get_thread_data()->debug_info = &initial_info;
init_done = TRUE;
}
......@@ -2890,6 +2890,7 @@ static TEB *init_teb( void *ptr, PEB *peb )
*/
TEB *virtual_alloc_first_teb(void)
{
struct ntdll_thread_data *thread_data;
TEB *teb;
PEB *peb;
void *ptr;
......@@ -2916,6 +2917,8 @@ TEB *virtual_alloc_first_teb(void)
peb = init_peb( (char *)teb_block + 31 * block_size );
teb = init_teb( ptr, peb );
*(ULONG_PTR *)&peb->CloudFileFlags = get_image_address();
thread_data = (struct ntdll_thread_data *)&teb->GdiTebBatch;
thread_data->debug_info = (struct debug_info *)((char *)teb_block + 31 * block_size + 2 * page_size);
return teb;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment