Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save maki-rxrz/ee6ebea99f01f4e8b81a0d487abe56a1 to your computer and use it in GitHub Desktop.
Save maki-rxrz/ee6ebea99f01f4e8b81a0d487abe56a1 to your computer and use it in GitHub Desktop.
L-SMASH patches
From 9a2728bd4d1b5fd462f73d5358449a5e0efe756b Mon Sep 17 00:00:00 2001
From: Masaki Tanaka <maki.rxrz@gmail.com>
Date: Wed, 5 Jul 2017 22:21:17 +0900
Subject: [PATCH] importer: Fix a crash caused by null pointer access.
---
importer/importer.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/importer/importer.c b/importer/importer.c
index f75c5d3..902390b 100644
--- a/importer/importer.c
+++ b/importer/importer.c
@@ -101,7 +101,7 @@ void lsmash_importer_destroy( importer_t *importer )
lsmash_remove_list( importer->summaries, lsmash_cleanup_summary );
lsmash_free( importer );
/* Prevent freeing this already freed importer in file's destructor again. */
- if( file->importer )
+ if( file && file->importer )
file->importer = NULL;
}
--
2.13.0.windows.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment