Plug file descriptor leak.

Change-Id: I882cc5c264fdf97452c84bd5cea0e5d56bd6eb45
Reviewed-on: https://code.wireshark.org/review/11753
Reviewed-by: Guy Harris <guy@alum.mit.edu>
This commit is contained in:
Guy Harris 2015-11-11 17:48:14 -08:00
parent 75dc2051e8
commit 412ab838d2
1 changed files with 1 additions and 0 deletions

View File

@ -2280,6 +2280,7 @@ wtap_dump_open_tempfile_ng(char **filenamep, const char *pfx,
fh = wtap_dump_file_fdopen(wdh, fd);
if (fh == NULL) {
*err = errno;
close(fd);
g_free(wdh);
return NULL; /* can't create file */
}