From 11c4b29d3a3c1f3491e0822eb50fc3c285a047d2 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Tue, 8 May 2007 01:35:26 +0000 Subject: (python-guess-indent): Check non-nullness before comparing indent against the 2..8 interval. --- lisp/progmodes/python.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lisp/progmodes/python.el') diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index e57c7e639c9..17d30e0d972 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -461,7 +461,7 @@ Set `python-indent' locally to the value guessed." (let ((initial (current-indentation))) (if (zerop (python-next-statement)) (setq indent (- (current-indentation) initial))) - (if (and (>= indent 2) (<= indent 8)) ; sanity check + (if (and indent (>= indent 2) (<= indent 8)) ; sanity check (setq done t)))))) (when done (when (/= indent (default-value 'python-indent)) -- cgit v1.2.1