From: Tomas Hruby Date: Fri, 4 Nov 2011 18:25:27 +0000 (+0000) Subject: KERNEL - mini_senda simplification X-Git-Tag: v3.2.0~136 X-Git-Url: http://zhaoyanbai.com/repos/icons/debian/static/datamaps.china.min.js?a=commitdiff_plain;h=c82a5dd3e367aee77798c11460dbfa639199e399;p=minix.git KERNEL - mini_senda simplification --- diff --git a/kernel/proc.c b/kernel/proc.c index c46edc3f2..5f7523c7f 100644 --- a/kernel/proc.c +++ b/kernel/proc.c @@ -1184,21 +1184,18 @@ PRIVATE int mini_senda(struct proc *caller_ptr, asynmsg_t *table, size_t size) set_sys_bit(priv(dst_ptr)->s_asyn_pending, priv(caller_ptr)->s_id); pending_recv = TRUE; + done = FALSE; + continue; } - if (!pending_recv) flags |= AMF_DONE; /* Done handling message */ - /* Store results */ tabent.result = r; - tabent.flags = flags; - if (flags & AMF_DONE) { - if (flags & AMF_NOTIFY) - do_notify = TRUE; - else if (r != OK && (flags & AMF_NOTIFY_ERR)) - do_notify = TRUE; - A_INSRT(i); /* Copy results to caller */ - } else - done = FALSE; + tabent.flags = flags | AMF_DONE; + if (flags & AMF_NOTIFY) + do_notify = TRUE; + else if (r != OK && (flags & AMF_NOTIFY_ERR)) + do_notify = TRUE; + A_INSRT(i); /* Copy results to caller */ } if (do_notify)