async errors.

This commit is contained in:
Ben Vanik 2015-05-14 17:13:54 -07:00
parent 9ea88ff901
commit 380fabebe7
1 changed files with 7 additions and 1 deletions

View File

@ -162,7 +162,13 @@ SHIM_CALL XamEnumerate_shim(PPCContext* ppc_state, KernelState* state) {
XEnumerator* e = nullptr;
if (XFAILED(state->object_table()->GetObject(handle, (XObject**)&e))) {
SHIM_SET_RETURN_64(X_ERROR_INVALID_HANDLE);
if (overlapped_ptr) {
state->CompleteOverlappedImmediateEx(overlapped_ptr, 0,
X_ERROR_INVALID_HANDLE, 0);
SHIM_SET_RETURN_64(X_ERROR_IO_PENDING);
} else {
SHIM_SET_RETURN_64(X_ERROR_INVALID_HANDLE);
}
return;
}