]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Do not access a released memory.
authorMichihiro NAKAJIMA <ggcueroad@gmail.com>
Wed, 28 Apr 2010 11:21:35 +0000 (07:21 -0400)
committerMichihiro NAKAJIMA <ggcueroad@gmail.com>
Wed, 28 Apr 2010 11:21:35 +0000 (07:21 -0400)
SVN-Revision: 2327

libarchive/archive_write_set_format_iso9660.c

index 0d9a1056d5297812aa07ad9ee2b4066d8fca6c4c..410416b1cae58e57179cbb1fe03c26aaac2c1bdb 100644 (file)
@@ -7385,14 +7385,14 @@ zisofs_fix_bootfile(struct archive_write *a)
        isoent = isoent_find_entry(iso9660->primary.rootent,
            str.s);
        if (isoent == NULL) {
-               archive_string_free(&str);
-               archive_string_free(&parentdir);
-               archive_string_free(&basename);
                archive_set_error(&a->archive,
                    ARCHIVE_ERRNO_MISC,
                    "Specified file ``%s'' which disable to "
                    " be zisofs is not found.",
                    str.s);
+               archive_string_free(&str);
+               archive_string_free(&parentdir);
+               archive_string_free(&basename);
                return (ARCHIVE_FATAL);
        }
        if (isoent->file->zisofs.keep_original) {