Commit 2eeb871
Changed files (1)
kilo.c
@@ -97,7 +97,11 @@ int get_window_size(int *rows, int *cols) {
void editor_draw_rows() {
for (int i = 0; i < E.screenrows; i++) {
- write(STDOUT_FILENO, "~\r\n", 3);
+ write(STDOUT_FILENO, "~", 1);
+
+ if (i < E.screenrows - 1) {
+ write(STDOUT_FILENO, "\r\n", 2);
+ }
}
}