Skip to content

Commit

Permalink
Fix goto prompt quit with error message
Browse files Browse the repository at this point in the history
  • Loading branch information
evanlin96069 committed Dec 29, 2023
1 parent 5608e1c commit 8df07a8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/prompt.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ char* editorPrompt(char* prompt, int state, void (*callback)(char*, int)) {
}

static void editorGotoCallback(char* query, int key) {
if (query == NULL || key == ESC)
if (query == NULL || key == ESC || key == CTRL_KEY('q'))
return;

int line = atoi(query);
Expand Down

0 comments on commit 8df07a8

Please sign in to comment.