# HG changeset patch # User Matti Hamalainen # Date 1411821025 -10800 # Node ID 3ce9d219819345d98afd15fd8b4f28caa94ce29f # Parent 810dc2fae474884c71d99ae199ea7222619526ee Grab the actual loading address from data block if PSID header loadAddr value is 0. diff -r 810dc2fae474 -r 3ce9d2198193 sidinfo.c --- a/sidinfo.c Fri Sep 26 04:57:05 2014 +0300 +++ b/sidinfo.c Sat Sep 27 15:30:25 2014 +0300 @@ -384,6 +384,9 @@ THERR("Error reading song data, unexpectedly small file.\n"); goto error; } + + // Grab the actual load address + psid->loadAddress = TH_LE16_TO_NATIVE(*(uint16_t *) fileData); // Strip load address (2 first bytes) th_md5_append(&state, &fileData[2], read - 2);