(add): Plug file descriptor leak.

This commit is contained in:
Markus Armbruster 2007-07-27 20:23:47 +00:00
parent f915f91b47
commit e1cd0bdc21

View file

@ -36,6 +36,8 @@
#include <fcntl.h>
#if defined(_WIN32)
#include <io.h>
#else
#include <unistd.h>
#endif
#include <sys/stat.h>
@ -214,7 +216,7 @@ add(void)
natp->nat_rejects[i] = 0;
natp->nat_newstim = 0;
natp->nat_annotim = 0;
(void)creat(mailbox(buf, coun), S_IRWUG);
close(creat(mailbox(buf, coun), S_IRWUG));
} else
pr("No special initializations done...\n");