request: Fixed a crash in wait()