From e7acf1609599f80804641db620951e9e91e99378 Mon Sep 17 00:00:00 2001 From: Andrew Pamment Date: Sun, 10 Sep 2017 20:22:56 +1000 Subject: [PATCH] Fix a bug with backspace --- utils/magiedit/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/magiedit/main.c b/utils/magiedit/main.c index abbc18a..24451fd 100644 --- a/utils/magiedit/main.c +++ b/utils/magiedit/main.c @@ -421,7 +421,7 @@ char *message_editor() { od_set_cursor(i - top_of_screen + 5, 1); od_clr_line(); } - } else { + } else if (position_x > 0) { if (position_x >= strlen(line)) { strncpy(line_cpy, line, strlen(line) - 1); line_cpy[strlen(line) - 1] = '\0';