]> git.sur5r.net Git - c128-kasse/commitdiff
backspace in get_input(): write \0-bytes
authorMichael Stapelberg <michael@stapelberg.de>
Sat, 29 Sep 2012 11:43:20 +0000 (13:43 +0200)
committerMichael Stapelberg <michael@stapelberg.de>
Sat, 29 Sep 2012 11:43:20 +0000 (13:43 +0200)
src/general.c

index cae149a6dc86eedc2eb2feb9f7f672f960845b3b..d40627e00bc04c586cd84fe3abd3bb810f332d87 100644 (file)
@@ -33,7 +33,7 @@ char *get_input() {
                        break;
                /* backspace? */
                if (c == 20) {
-                       i--;
+                       output[--i] = '\0';
                        cputcxy(x+i, y, ' ');
                        gotoxy(x+i, y);
                        continue;