Commit 8447b2b0f09fd4dd1271363a161c7ff347e684bd

antirez 2014-03-13T12:20:11

Fix right arrow handling. Bug introduced in recent refactoring.

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/linenoise.c b/linenoise.c
index 708e3c9..672e36e 100644
--- a/linenoise.c
+++ b/linenoise.c
@@ -808,7 +808,7 @@ static int linenoiseEdit(int stdin_fd, int stdout_fd, char *buf, size_t buflen, 
                         linenoiseEditHistoryNext(&l, LINENOISE_HISTORY_NEXT);
                         break;
                     case 'C':
-                        linenoiseEditMoveLeft(&l);
+                        linenoiseEditMoveRight(&l);
                         break;
                     case 'D':
                         linenoiseEditMoveLeft(&l);