|
107 | 107 | #include <stdlib.h> |
108 | 108 | #include <stdint.h> |
109 | 109 | #include <stdio.h> |
| 110 | +#include "sdkconfig.h" |
110 | 111 | #if !CONFIG_IDF_TARGET_LINUX |
111 | 112 | // On Linux, we don't need __fbufsize (see comments below), and |
112 | 113 | // __fbufsize not available on MacOS (which is also considered "Linux" target) |
@@ -580,7 +581,7 @@ static void refreshMultiLine(struct linenoiseState *l) { |
580 | 581 | int rows = (plen+l->len+l->cols-1)/l->cols; /* rows used by current buf. */ |
581 | 582 | int rpos = (plen+l->oldpos+l->cols)/l->cols; /* cursor relative row. */ |
582 | 583 | int rpos2; /* rpos after refresh. */ |
583 | | - int col; /* colum position, zero-based. */ |
| 584 | + int col; /* column position, zero-based. */ |
584 | 585 | int old_rows = l->maxrows; |
585 | 586 | int j; |
586 | 587 | int fd = fileno(stdout); |
@@ -635,7 +636,7 @@ static void refreshMultiLine(struct linenoiseState *l) { |
635 | 636 | rpos2 = (plen+l->pos+l->cols)/l->cols; /* current cursor relative row. */ |
636 | 637 | lndebug("rpos2 %d", rpos2); |
637 | 638 |
|
638 | | - /* Go up till we reach the expected positon. */ |
| 639 | + /* Go up till we reach the expected position. */ |
639 | 640 | if (rows-rpos2 > 0) { |
640 | 641 | lndebug("go-up %d", rows-rpos2); |
641 | 642 | snprintf(seq,64,"\x1b[%dA", rows-rpos2); |
@@ -796,7 +797,7 @@ void linenoiseEditBackspace(struct linenoiseState *l) { |
796 | 797 | } |
797 | 798 | } |
798 | 799 |
|
799 | | -/* Delete the previosu word, maintaining the cursor at the start of the |
| 800 | +/* Delete the previous word, maintaining the cursor at the start of the |
800 | 801 | * current word. */ |
801 | 802 | void linenoiseEditDeletePrevWord(struct linenoiseState *l) { |
802 | 803 | size_t old_pos = l->pos; |
|
0 commit comments