diff options
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/startup.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/startup.el b/lisp/startup.el index 90046389d16..7759ed5aed3 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -2413,7 +2413,9 @@ nil default-directory" name) (read-data (read-from-string str-expr)) (expr (car read-data)) (end (cdr read-data))) - (unless (= end (length str-expr)) + ;; Allow same trailing chars as minibuf.c's + ;; `string_to_object'. + (unless (string-match-p "[\s\t\n]*\\'" str-expr end) (error "Trailing garbage following expression: %s" (substring str-expr end))) (eval expr t))) |