First of all, I'd like to clarify, if maybe I did not make it clear, but I'm using a custom threading library built on top of Qt. So I'm not quite sure if I use evthread_use_windows_threads() *IN CONJUNCTION WITH* evthread_set_id_callback, evthread_set_condition_callbacks, and evthread_set_lock_callbacks. I figured if I'm going to be using a custom thread library that I'd use neither evthread_use_windows_threads nor evthread_use_posix_threads.
Secondly, I took your suggestion and called evthread_use_windows_threads() as the first thing I do and it still crashed. I am attaching the code below.
Perhaps as a sanity check, it would be nice if someone would at least say "yes/no evhttp was/wasn't meant to be used in the way you're using it"
evthread_use_windows_threads();
...
evthread_set_id_callback(&EvThread::id_fn);
evthread_condition_callbacks cond_cbs;
cond_cbs.condition_api_version = 1.0;
cond_cbs.alloc_condition = &EvWaitCond::alloc_condition;
cond_cbs.free_condition = &EvWaitCond::free_condition;
cond_cbs.signal_condition = &EvWaitCond::signal_condition;
cond_cbs.wait_condition = &EvWaitCond::wait_condition;
evthread_set_condition_callbacks(&cond_cbs);
evthread_lock_callbacks lock_cbs;
lock_cbs.lock_api_version = 1.0;
lock_cbs.supported_locktypes = EVTHREAD_LOCKTYPE_RECURSIVE;
lock_cbs.alloc = &EvLock::alloc;
lock_cbs.free = &EvLock::free;
lock_cbs.lock = &EvLock::lock;
lock_cbs.unlock = &EvLock::unlock;
evthread_set_lock_callbacks(&lock_cbs);