changeset 1190:51eb5788c1fc

Add a NULL pointer check here.
author Matti Hamalainen <ccr@tnsp.org>
date Thu, 05 Mar 2015 13:10:16 +0200
parents bd2615822bbf
children 1f1225b509fb
files minijss/jloadxm.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/minijss/jloadxm.c	Thu Mar 05 13:06:40 2015 +0200
+++ b/minijss/jloadxm.c	Thu Mar 05 13:10:16 2015 +0200
@@ -972,7 +972,7 @@
             for (index = 0; index < module->nextInstruments; index++)
             {
                 JSSExtInstrument *einst = module->extInstruments[index];
-                if ((ret = jssXMLoadInstrumentSamples(inFile, module, einst, index)) != DMERR_OK)
+                if (einst != NULL && (ret = jssXMLoadInstrumentSamples(inFile, module, einst, index)) != DMERR_OK)
                     goto out;
             }
             break;