From 811eaa609c80ca9381d1310028018cbfb1b673f1 Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Sun, 18 Jul 1993 20:01:03 +0000 Subject: [PATCH] (update-file-autoloads): Go to the beginning of FILE before searching it for generate-autoload-cookie. --- lisp/emacs-lisp/autoload.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lisp/emacs-lisp/autoload.el b/lisp/emacs-lisp/autoload.el index 0950a1af574..8c184070be3 100644 --- a/lisp/emacs-lisp/autoload.el +++ b/lisp/emacs-lisp/autoload.el @@ -263,7 +263,10 @@ autoloads go somewhere else.") (if (save-excursion (set-buffer (find-file-noselect file)) (save-excursion - (search-forward generate-autoload-cookie nil t))) + (save-restriction + (widen) + (goto-char (point-min)) + (search-forward generate-autoload-cookie nil t)))) ;; There are autoload cookies in FILE. ;; Have the user tell us where to put the new section. (progn -- 2.39.5