summaryrefslogtreecommitdiff
path: root/pflocal/pflocal.c
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>1996-01-27 17:36:11 +0000
committerMiles Bader <miles@gnu.org>1996-01-27 17:36:11 +0000
commit382689076dc76ace84767b823e729015f5dd76f1 (patch)
treedd2a845a50ed58de1a3fe917669eae48e526a6a5 /pflocal/pflocal.c
parentb864fae76ba5c26646accc6fcfd6c2c50560531e (diff)
(trivfs_goaway): Handle errors from ports_inhibit_bucket_rpcs.
(thread_cancel): Function deleted.
Diffstat (limited to 'pflocal/pflocal.c')
-rw-r--r--pflocal/pflocal.c28
1 files changed, 12 insertions, 16 deletions
diff --git a/pflocal/pflocal.c b/pflocal/pflocal.c
index 56ec622a..27148bd6 100644
--- a/pflocal/pflocal.c
+++ b/pflocal/pflocal.c
@@ -108,25 +108,21 @@ trivfs_modify_stat (struct trivfs_protid *cred, struct stat *st)
error_t
trivfs_goaway (struct trivfs_control *fsys, int flags)
{
- error_t err;
-
- /* Stop all I/O. */
- ports_inhibit_bucket_rpcs (pf_port_bucket);
+ int force = (flags & FSYS_GOAWAY_FORCE);
+ error_t err = ports_inhibit_bucket_rpcs (pf_port_bucket); /* Stop all I/O. */
- /* Now see if there are any old sockets lying around. */
- err = sock_global_shutdown ();
+ if (err == 0 || (err != EINTR && force))
+ {
+ /* Now see if there are any old sockets lying around. */
+ err = sock_global_shutdown ();
- /* Exit if not, or if we must. */
- if (err == 0 || flags & FSYS_GOAWAY_FORCE)
- exit (0);
+ /* Exit if not, or if we must. */
+ if (err == 0 || force)
+ exit (0);
- /* We won't go away, so start things going again... */
- ports_resume_bucket_rpcs (pf_port_bucket);
+ /* We won't go away, so start things going again... */
+ ports_resume_bucket_rpcs (pf_port_bucket);
+ }
return err;
}
-
-void
-thread_cancel (thread_t foo __attribute__ ((unused)))
-{
-}