# HG changeset patch # User Chong Yidong # Date 1130282687 0 # Node ID ce840b1d13ad561b0e48798922a8c9dd56551689 # Parent 50f2dd53cf9a5dd1e10ff21f51109f3982862740 * longlines.el (longlines-mode): Remove narrowing before performing the initial decoding or final encoding. diff -r 50f2dd53cf9a -r ce840b1d13ad lisp/ChangeLog --- a/lisp/ChangeLog Tue Oct 25 21:28:54 2005 +0000 +++ b/lisp/ChangeLog Tue Oct 25 23:24:47 2005 +0000 @@ -1,3 +1,8 @@ +2005-10-25 Chong Yidong + + * longlines.el (longlines-mode): Remove narrowing before + performing the initial decoding or final encoding. + 2005-10-25 Romain Francoise * emacs-lisp/find-func.el (find-library-name): Also strip diff -r 50f2dd53cf9a -r ce840b1d13ad lisp/longlines.el --- a/lisp/longlines.el Tue Oct 25 21:28:54 2005 +0000 +++ b/lisp/longlines.el Tue Oct 25 23:24:47 2005 +0000 @@ -123,7 +123,9 @@ ;; Turning off undo is OK since (spaces + newlines) is ;; conserved, except for a corner case in ;; longlines-wrap-lines that we'll never encounter from here - (longlines-decode-region (point-min) (point-max)) + (save-restriction + (widen) + (longlines-decode-region (point-min) (point-max))) (longlines-wrap-region (point-min) (point-max)) (set-buffer-modified-p mod)) (when (and longlines-show-hard-newlines @@ -141,7 +143,9 @@ (longlines-unshow-hard-newlines)) (let ((buffer-undo-list t) (inhibit-read-only t)) - (longlines-encode-region (point-min) (point-max))) + (save-restriction + (widen) + (longlines-encode-region (point-min) (point-max)))) (remove-hook 'change-major-mode-hook 'longlines-mode-off t) (remove-hook 'before-kill-functions 'longlines-encode-region t) (remove-hook 'after-change-functions 'longlines-after-change-function t)