SCCS-vsn: usr.bin/tn3270/sys_curses/system.c 4.2
-static char sccsid[] = "@(#)system.c 4.1 (Berkeley) %G%";
+static char sccsid[] = "@(#)system.c 4.2 (Berkeley) %G%";
#endif /* not lint */
#include <sys/types.h>
#endif /* not lint */
#include <sys/types.h>
#define fd_set fdset_t
#endif /* defined(pyr) */
#define fd_set fdset_t
#endif /* defined(pyr) */
-#if !defined(sun) && !defined(pyr)
-#include <sys/inode.h>
-#else /* !defined(sun) */
+/*
+ * Wouldn't it be nice if these REALLY were in <sys/inode.h>? Or,
+ * equivalently, if <sys/inode.h> REALLY existed?
+ */
#define IREAD 00400
#define IWRITE 00200
#define IREAD 00400
#define IWRITE 00200
-#endif /* !defined(sun) */
#include <sys/file.h>
#include <sys/time.h>
#include <sys/file.h>
#include <sys/time.h>
kill_connection();
return -1;
}
kill_connection();
return -1;
}
+ /* At this point, it is possible that we've gone away */
+ if (shell_active == 0) {
+ kill_connection();
+ return -1;
+ }
if (api_exch_init(sock, "server") == -1) {
return -1;
}
if (api_exch_init(sock, "server") == -1) {
return -1;
}