linenoise BUGFIX refresh columns on each line refresh
@@ -697,6 +697,9 @@ static void refreshMultiLine(struct linenoiseState *l) {
/* Calls the two low level functions refreshSingleLine() or
* refreshMultiLine() according to the selected mode. */
void linenoiseRefreshLine(void) {
+ /* Update columns in case the terminal was resized */
+ ls.cols = getColumns(STDIN_FILENO, STDOUT_FILENO);
+
if (mlmode)
refreshMultiLine(&ls);
else
