diff options
-rw-r--r-- | src/kilo.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/kilo.c b/src/kilo.c index 310e509..1b321fc 100644 --- a/src/kilo.c +++ b/src/kilo.c @@ -1171,17 +1171,9 @@ void editorProcessKeypress(int fd) { * to the edited file. */ break; case CTRL_E: - /* Quit if the file was already saved. */ - if (E.dirty && quit_times) { - editorSetStatusMessage("WARNING!!! File has unsaved changes. " - "Press Ctrl-E %d more times to quit.", quit_times); - quit_times--; - return; - } - Quit = 1; - break; - case CTRL_S: + /* Save and quit. */ editorSave(); + Quit = 1; break; case CTRL_F: editorFind(fd); |