April 29, 2026
4:50 a.m.
On Wed Apr 29 09:46:10 2026 +0000, Twaik Yont wrote:
It calls `NtCurrentTeb()`. `dlls/ntdll/thread.c` ``` static void init_options(void) { unsigned int offset = page_size * (sizeof(void *) / 4); debug_options = (struct __wine_debug_channel *)((char *)NtCurrentTeb()->Peb + offset); while (debug_options[nb_debug_options].name[0]) nb_debug_options++; } ``` That's the PE version, but you are running on the Unix side, the code is in dlls/ntdll/unix/debug.c.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/10710#note_138164