diff --git a/source/vibe/core/sync.d b/source/vibe/core/sync.d index 78a356b..4b76bbd 100644 --- a/source/vibe/core/sync.d +++ b/source/vibe/core/sync.d @@ -923,8 +923,10 @@ struct ManualEvent { () @trusted { logTrace("wait shared %s", cast(void*)&this); } (); - if (ms_threadEvent is EventID.invalid) + if (ms_threadEvent is EventID.invalid) { ms_threadEvent = eventDriver.events.create(); + assert(ms_threadEvent != EventID.invalid, "Failed to create event!"); + } SysTime target_timeout, now; if (timeout != Duration.max) {