From 2467932310c83a430164c4f19e29d1115fa24aea Mon Sep 17 00:00:00 2001 From: Adam Spiers Date: Mon, 5 Mar 2012 21:18:29 -0500 Subject: [PATCH] calendar-set-mode-line fix (tiny change) * lisp/calendar/calendar.el (calendar-set-mode-line): `getenv' returns a string. Fixes: debbugs:10951 --- lisp/ChangeLog | 5 +++++ lisp/calendar/calendar.el | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 394e082ecc8..7bf2ba1bcc2 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2012-03-06 Adam Spiers (tiny change) + + * calendar/calendar.el (calendar-set-mode-line): + `getenv' returns a string. (Bug#10951) + 2012-03-05 Leo Liu * simple.el (backward-delete-char-untabify): Constrain point to diff --git a/lisp/calendar/calendar.el b/lisp/calendar/calendar.el index 24c284350a3..0c351c6072f 100644 --- a/lisp/calendar/calendar.el +++ b/lisp/calendar/calendar.el @@ -2602,7 +2602,7 @@ If called by a mouse-event, pops up a menu with the result." ;; If no frame exists yet, we have no idea what width to use. (and (= width 10) (not window-system) - (setq width (or (getenv "COLUMNS") 80))) + (setq width (string-to-number (or (getenv "COLUMNS") "80")))) (setq mode-line-format (if buffer-file-name `("-" mode-line-modified -- 2.39.2