diff --git a/lib/codemirror.js b/lib/codemirror.js
index <HASH>..<HASH> 100644
--- a/lib/codemirror.js
+++ b/lib/codemirror.js
@@ -1629,7 +1629,7 @@ var CodeMirror = (function() {
             if (hidden && l.length == maxLine.length) {
               updateMaxLine = true;
             } else if (!hidden && l.length > maxLine.length) {
-              maxLine = l; maxWidth = null; updateMaxLine = false;
+              maxLine = l; updateMaxLine = false;
             }
           }
           updateLineHeight(line, hidden ? 0 : 1);
Remove unused undeclared variable.