From 4003d88d7ba2eb3adefbbc6e87bafe2a647e49b2 Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Mon, 14 Aug 1995 22:17:20 +0000 Subject: [PATCH] (_hurd_setup_sighandler): In rpc_wait case, frob mach_msg args to set timeout on receive. --- sysdeps/mach/hurd/mips/trampoline.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sysdeps/mach/hurd/mips/trampoline.c b/sysdeps/mach/hurd/mips/trampoline.c index ba3450e1fb..03e3d1da6f 100644 --- a/sysdeps/mach/hurd/mips/trampoline.c +++ b/sysdeps/mach/hurd/mips/trampoline.c @@ -150,6 +150,12 @@ _hurd_setup_sighandler (struct hurd_sigstate *ss, __sighandler_t handler, calls we retry need only wait to receive the reply message. */ args->option &= ~MACH_SEND_MSG; + /* Limit the time to receive the reply message, in case the server + claimed that `interrupt_operation' succeeded but in fact the RPC + is hung. */ + args->option |= MACH_RCV_TIMEOUT; + args->timeout = _hurd_interrupted_rpc_timeout; + state->basic.pc = (int) &&rpc_wait_trampoline; state->basic.r29 = (int) sigsp; /* $29 is the stack pointer register. */ /* After doing the message receive, the trampoline code will need to