diff options
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/progmodes/gdb-mi.el | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/progmodes/gdb-mi.el b/lisp/progmodes/gdb-mi.el index ac76caf8d61..1a7f1841fb3 100644 --- a/lisp/progmodes/gdb-mi.el +++ b/lisp/progmodes/gdb-mi.el @@ -671,8 +671,10 @@ detailed description of this mode. (file-name-directory file)))) ((string-equal (match-string 1) "size") (setq hsize (match-string 2)))))))) - (if (integerp hsize) - (set (make-local-variable 'comint-input-ring-size) hsize)) + (and (stringp hsize) + (integerp (string-to-number hsize)) + (> hsize 0) + (set (make-local-variable 'comint-input-ring-size) hsize)) (if (stringp hfile) (set (make-local-variable 'comint-input-ring-file-name) hfile)) (comint-read-input-ring t))) |