From 07d689c6feda049d53569a5d5965407dbde23a1f Mon Sep 17 00:00:00 2001 From: Andrew Pamment Date: Sun, 10 Sep 2017 20:32:42 +1000 Subject: [PATCH] And again.. --- utils/magiedit/main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/utils/magiedit/main.c b/utils/magiedit/main.c index a9bf107..8acf2da 100644 --- a/utils/magiedit/main.c +++ b/utils/magiedit/main.c @@ -356,7 +356,7 @@ char *message_editor() { } position_y--; - position_x = strlen(line) - 1; + position_x = strlen(line); } else { memcpy(line, body_lines[body_line_count -1], 81); free(body_lines[body_line_count - 1]); @@ -367,7 +367,7 @@ char *message_editor() { body_lines = (char **)realloc(body_lines, sizeof(char *) * (body_line_count)); } position_y--; - position_x = strlen(line) - 1; + position_x = strlen(line); } } else { @@ -393,7 +393,7 @@ char *message_editor() { } position_y--; - position_x = j - 1; + position_x = j; } else { // it doesn't fit move cursor to end of previous line