From: Chong Yidong Date: Sat, 5 May 2012 05:13:27 +0000 (+0800) Subject: Fix package.el handling of local variables on first line. X-Git-Tag: emacs-24.0.97~31 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=f677562b6c90b283d338725992d87a2770848560;p=emacs.git Fix package.el handling of local variables on first line. * lisp/emacs-lisp/package.el (package-buffer-info): Avoid putting local variables into description. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7a83c95ec3a..2442582114d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2012-05-05 Chong Yidong + + * emacs-lisp/package.el (package-buffer-info): Avoid putting local + variables into description. + 2012-05-05 Stefan Monnier * shell.el (shell-completion-vars): Set pcomplete-arg-quote-list like diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el index 5b158eb994f..73afdb82509 100644 --- a/lisp/emacs-lisp/package.el +++ b/lisp/emacs-lisp/package.el @@ -943,7 +943,7 @@ If the buffer does not contain a conforming package, signal an error. If there is a package, narrow the buffer to the file's boundaries." (goto-char (point-min)) - (unless (re-search-forward "^;;; \\([^ ]*\\)\\.el --- \\(.*\\)$" nil t) + (unless (re-search-forward "^;;; \\([^ ]*\\)\\.el ---[ \t]*\\(.*?\\)[ \t]*\\(-\\*-.*-\\*-[ \t]*\\)?$" nil t) (error "Packages lacks a file header")) (let ((file-name (match-string-no-properties 1)) (desc (match-string-no-properties 2))