From d5986c2929235cd0265378f8c23a259f9b621298 Mon Sep 17 00:00:00 2001 From: "Robert S. French" Date: Wed, 10 Jun 1987 09:27:01 +0000 Subject: Fixed closing problem with ZSetFD --- lib/ZClosePort.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/ZClosePort.c') diff --git a/lib/ZClosePort.c b/lib/ZClosePort.c index 0853d00..27e7e18 100644 --- a/lib/ZClosePort.c +++ b/lib/ZClosePort.c @@ -18,10 +18,11 @@ Code_t ZClosePort() { - if (__Zephyr_fd >= 0) + if (__Zephyr_fd >= 0 && __Zephyr_open) close(__Zephyr_fd); __Zephyr_fd = -1; - + __Zephyr_open = 0; + return (ZERR_NONE); } -- cgit v1.2.3