Changes in emu/ser.c [8c8a883:657abdf] in buchla-emu
Legend:
- Unmodified
- Added
- Removed
-
emu/ser.c
r8c8a883 r657abdf 60 60 }; 61 61 62 static uint8_t mem[CON_H][CON_W ];62 static uint8_t mem[CON_H][CON_W + 1]; 63 63 64 64 static SDL_Window *win; … … 81 81 static void scroll(void) 82 82 { 83 memmove(mem, mem + 1, (CON_H - 1) * CON_W);83 memmove(mem, mem + 1, (CON_H - 1) * (CON_W + 1)); 84 84 memset(mem + (CON_H - 1), ' ', CON_W); 85 85 } … … 256 256 for (int32_t y = 0; y < CON_H; ++y) { 257 257 char line[CON_W + 1]; 258 line[CON_W] = 0;259 258 260 259 if (SDL_LockMutex(cpu_mutex) < 0) { … … 262 261 } 263 262 264 memcpy(line, mem[y], CON_W );263 memcpy(line, mem[y], CON_W + 1); 265 264 266 265 if (SDL_UnlockMutex(cpu_mutex) < 0) { … … 516 515 mem[y][x] = ' '; 517 516 } 517 518 mem[y][CON_W] = 0; 518 519 } 519 520 }
Note:
See TracChangeset
for help on using the changeset viewer.