Hi Rémi,
On 04.02.2020 11:09, Rémi Bernon wrote:
}
- else if (get_error() == STATUS_KERNEL_APC)
- {
if (!(apc = thread_dequeue_apc( current, 1 )))
return;
Unlike user APC case (where we have a loop), thread_dequeue_apc will never return NULL here.
if (!(reply->apc_handle = alloc_handle( current->process, apc, SYNCHRONIZE, 0 )))
return;
You leak apc in error case here and leave it in an inconsistent state (it will never finish, blocking the caller). And yeah, current code is not exactly right neither, but a bit better error handling would be nice.
Thanks,
Jacek