# HG changeset patch # User Matti Hamalainen # Date 1425442102 -7200 # Node ID 0888764d01cde70015ad0642de4e4c4b9ecdb58d # Parent 44ed439b1c6b3feede60cab65f54b67aa52b02db Cosmetics. diff -r 44ed439b1c6b -r 0888764d01cd minijss/jloadxm.c --- a/minijss/jloadxm.c Wed Mar 04 06:08:11 2015 +0200 +++ b/minijss/jloadxm.c Wed Mar 04 06:08:22 2015 +0200 @@ -408,10 +408,9 @@ static int jssXMLoadExtInstrument(DMResource *inFile, int ninst, JSSModule *module) { XMInstrument1 xmI1; - off_t pos, remainder; + off_t remainder, pos = dmftell(inFile); // Get instrument header #1 - pos = dmftell(inFile); if (!dmf_read_le32(inFile, &xmI1.headSize) || !dmf_read_str(inFile, &xmI1.instName, sizeof(xmI1.instName)) || !dmf_read_byte(inFile, &xmI1.instType) || @@ -612,10 +611,8 @@ for (index = 0; index < module->npatterns; index++) { - off_t pos, remainder; - // Get the pattern header - pos = dmftell(inFile); + off_t remainder, pos = dmftell(inFile); if (!dmf_read_le32(inFile, &xmP.headSize) || !dmf_read_byte(inFile, &xmP.packing) || @@ -668,7 +665,8 @@ for (index = 0; index < module->norders; index++) { int tmp = xmH->orderList[index]; - if (tmp >= module->npatterns || module->patterns[tmp] == NULL) + if (tmp >= module->npatterns || + module->patterns[tmp] == NULL) tmp = jsetMaxPatterns; module->orderList[index] = tmp;