]> granicus.if.org Git - xz/commitdiff
Fixed a dangling pointer that caused invalid free().
authorLasse Collin <lasse.collin@tukaani.org>
Tue, 22 Jan 2008 22:18:32 +0000 (00:18 +0200)
committerLasse Collin <lasse.collin@tukaani.org>
Tue, 22 Jan 2008 22:18:32 +0000 (00:18 +0200)
src/liblzma/common/info.c

index 2a59a029652c0933d0ceeab0a02cfceff291b1d1..cbd32d6b64c90f9260b00e6274556a5521e4c59e 100644 (file)
@@ -385,6 +385,7 @@ lzma_info_metadata_set(lzma_info *info, lzma_allocator *allocator,
 
                const lzma_ret ret = lzma_info_index_set(
                                info, allocator, metadata->index, eat_index);
+               metadata->index = NULL;
                if (ret != LZMA_OK)
                        return ret;