Abort if unable to write pid file.
authorYang Tse <yangsita@gmail.com>
Wed, 19 Jul 2006 15:26:28 +0000 (15:26 +0000)
committerYang Tse <yangsita@gmail.com>
Wed, 19 Jul 2006 15:26:28 +0000 (15:26 +0000)
tests/server/sws.c

index db774f6..7c3ba4f 100644 (file)
@@ -802,6 +802,8 @@ int main(int argc, char *argv[])
   }
   else {
     fprintf(stderr, "Couldn't write pid file\n");
+    sclose(sock);
+    exit(1);
   }
 
   logmsg("Running IPv%d version on port %d",