[tor-dev] [Win32] crash in test/bench.exe

Gisle Vanem gisle.vanem at gmail.com
Tue Mar 13 12:09:57 UTC 2018


There is a crash in bench.exe. Running 'cdb -c g bench.exe':

ntdll!RtlpWaitOnCriticalSection+0x6b:
77a9cfd6 ff4014          inc     dword ptr [eax+14h]  ds:002b:00000014=????????

ChildEBP RetAddr
0137f750 77aba38a ntdll!RtlpWaitOnCriticalSection+0x6b
0137f770 77aba259 ntdll!RtlpEnterCriticalSectionContended+0x12a
*** WARNING: Unable to verify checksum for bench.exe
0137f77c 002150f7 ntdll!RtlEnterCriticalSection+0x49
0137f784 0023136c bench!tor_mutex_acquire(struct tor_mutex_t * m = 0x0039559c)+0x37
0137f794 000fc85f bench!atomic_counter_exchange(struct atomic_counter_t * counter = 0x0039559c, unsigned int newval = 6) 
+0xc
(Inline) -------- bench!set_protocol_warning_severity_level+0xb
0137f7bc 0010563f bench!options_act(struct or_options_t * old_options = 0x00000000)+0x2af
0137f7d4 000f385b bench!set_options(struct or_options_t * new_val = 0x0f335730, char ** msg = 0x0137f80c)+0x6f
0137f80c 002f3707 bench!main(int argc = 0n1, char ** argv = 0x036b1e38)+0x24b
...


Seems bench.c uses some mutex which is not initialised
with 'tor_mutex_init()'. I fail to see which that should
be.

FYI.
'&m->mutex' is 0 (= eax). But adding:
   tor_assert(&m->mutex);
   tor_assert(&m->mutex.OwningThread);
to 'tor_mutex_acquire()' didn't help reveal the problem.

-- 
--gv


More information about the tor-dev mailing list