diff options
Diffstat (limited to 'source')
-rw-r--r-- | source/snap.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/source/snap.c b/source/snap.c index 9ff0ae6..3ef3690 100644 --- a/source/snap.c +++ b/source/snap.c @@ -127,15 +127,21 @@ int TAPLoad(Z80Byte id, Z80Word *addr, Z80Word *len, SNAP_Poke poke) while(blen && *len) { b = GetTAPByte(); - csum ^= b; - poke(*addr,b); + if (blen > 1) + { + csum ^= b; + poke(*addr,b); + } (*addr)++; (*len)--; blen--; } + SPEC_DEBUG("Finished block. Remaining blen=%u len=%u\n", + (unsigned)blen, (unsigned)*len); + /* Get the checksum */ if (blen) |