diff --git a/exec/fseditor.js b/exec/fseditor.js
index 1e5df600af3619724c02cd3b973cd961d9e1173e..18db5d99bae0272f7b1b5cbbbf4e230c4ed904e5 100644
--- a/exec/fseditor.js
+++ b/exec/fseditor.js
@@ -312,7 +312,7 @@ function unwrap_line(l)
 	}
 	if(old_lines!=line.length) {
 		/* We need to redraw everything... line(s) deleted */
-		for(;l<line.length;l++)
+		for(;l<=line.length;l++)
 			draw_line(l);
 	}
 	return(ret);
@@ -1532,8 +1532,9 @@ function edit(quote_first)
 						line[ypos].hardcr=false;
 					}
 				}
-				if(!rewrap())
+				if(!rewrap()) {
 					draw_line(ypos,xpos);
+				}
 				break;
 			case '\x09':	/* CTRL-I TAB... ToDo expand to spaces */
 				add_char(' ');