Fixed seg. fault moving liens downwards.

This commit is contained in:
GrenderG committed 2017-04-10 03:50:50 +02:00
1 parent 1ebde52bce
commit 22799f4ac8
1 file changed
+2 -1
+2 -1
View File
@@ -891,7 +891,8 @@ void editorFlipRow(int dir) {
int first = (dir == 1) ? ec.cursor_y - 1 : ec.cursor_y;
editorUpdateSyntax(&ec.row[first]);
editorUpdateSyntax(&ec.row[first] + 1);
editorUpdateSyntax(&ec.row[first] + 2);
if (ec.num_rows - ec.cursor_y - 1 > 2)
editorUpdateSyntax(&ec.row[first] + 2);
ec.cursor_y -= dir;
ec.dirty++;