From 591a435f0c8a4dd4b8ddfe019ba8e5af3cacc93e Mon Sep 17 00:00:00 2001 From: "Michael I. Bushnell" Date: Tue, 21 Nov 1995 14:56:00 +0000 Subject: (ports_manage_port_operations_multithread/internal_demuxer): If the incoming RPC has already been cancelled, then call cancel_rpc instead of the user's demuxer. (cancel_rpc): New function. --- libports/manage-multithread.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) (limited to 'libports') diff --git a/libports/manage-multithread.c b/libports/manage-multithread.c index 87a9d278..26afa79a 100644 --- a/libports/manage-multithread.c +++ b/libports/manage-multithread.c @@ -23,6 +23,16 @@ #include #include +/* Fill in a cancellation error for the incoming RPC in inp + so that it will be retried. For now, just return junk. XXX */ +static void +cancel_rpc (mach_msg_header_t *inp, + mach_msg_header_t *outp) +{ +} + + + void ports_manage_port_operations_multithread (struct port_bucket *bucket, ports_demuxer_type demuxer, @@ -66,7 +76,13 @@ ports_manage_port_operations_multithread (struct port_bucket *bucket, if (pi) { ports_begin_rpc (pi, &link); - status = demuxer (inp, outp); + if (inp->msgh_seqno < pi->cancel_threshhold) + { + cancel_rpc (inp, outp); + status = 1; + } + else + status = demuxer (inp, outp); ports_end_rpc (pi, &link); ports_port_deref (pi); } -- cgit v1.2.3