Rearrange code to work around compiler parsing bugs
authorMark Tearle <[email protected]>
Sun, 30 Nov 2014 07:57:42 +0000 (15:57 +0800)
committerMark Tearle <[email protected]>
Sun, 30 Nov 2014 08:04:38 +0000 (16:04 +0800)
ROM2/main_basic.c

index 381db9c..a63c858 100644 (file)
@@ -443,12 +443,16 @@ void getrom() {
                return;
        }
        char s[4];
+       
+       u16 rom_addr;
+       rom_addr = (u16)(&_rom_src_data);
+
        send_string("Writing to serial port (maybe). Size is 0x");
        send_string(u82hex(_rom_src_len >> 8));
        send_string(u82hex(_rom_src_len & 0xff));
        send_string("@0x");
-       send_string(u82hex((u16)(&_rom_src_data) >> 8));
-       send_string(u82hex((u16)(&_rom_src_data) & 0xff));
+       send_string(u82hex(rom_addr >> 8));
+       send_string(u82hex(rom_addr & 0xff));
        send_string(" with signature ");
        s[0] = _rom_src_data[0];
        s[1] = _rom_src_data[1];

UCC git Repository :: git.ucc.asn.au