Plug another leak.

If cf_export_specified_packets() succeeds, and it wrote to a temporary
file, it leaks the name of the file to which it was writing.  Free that
after we've renamed that file on top of the target file (safe save).
This commit is contained in:
Guy Harris 2021-05-22 19:01:22 -07:00
parent 1502615794
commit 8ca86b29bf
1 changed files with 1 additions and 0 deletions

1
file.c
View File

@ -4902,6 +4902,7 @@ cf_export_specified_packets(capture_file *cf, const char *fname,
cf_rename_failure_alert_box(fname, errno);
goto fail;
}
g_free(fname_new);
}
return CF_WRITE_OK;