diff options
| author | Stefan Monnier | 2009-09-20 14:54:17 +0000 |
|---|---|---|
| committer | Stefan Monnier | 2009-09-20 14:54:17 +0000 |
| commit | e3f36d034a01edde47dfa5df0c9bbd3f2eff125c (patch) | |
| tree | 9a8b4d8459649e78cefe828a947a254896a1649e | |
| parent | 1dd4f2c41189d6977593603ecdd4f9260ffa2309 (diff) | |
| download | emacs-e3f36d034a01edde47dfa5df0c9bbd3f2eff125c.tar.gz emacs-e3f36d034a01edde47dfa5df0c9bbd3f2eff125c.zip | |
(bookmark-write-file): Avoid calling `pp' with large
list, to workaround performance problem (bug#4485).
| -rw-r--r-- | lisp/ChangeLog | 13 | ||||
| -rw-r--r-- | lisp/bookmark.el | 7 |
2 files changed, 15 insertions, 5 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 40362f6d39c..16eea2af93e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2009-09-20 Thierry Volpiatto <thierry.volpiatto@gmail.com> | ||
| 2 | |||
| 3 | * bookmark.el (bookmark-write-file): Avoid calling `pp' with large | ||
| 4 | list, to workaround performance problem (bug#4485). | ||
| 5 | |||
| 1 | 2009-09-20 Nick Roberts <nickrob@snap.net.nz> | 6 | 2009-09-20 Nick Roberts <nickrob@snap.net.nz> |
| 2 | 7 | ||
| 3 | * progmodes/gud.el (gud-sentinel): Revert indavertant change. | 8 | * progmodes/gud.el (gud-sentinel): Revert indavertant change. |
| @@ -17,8 +22,8 @@ | |||
| 17 | 22 | ||
| 18 | 2009-09-19 Chong Yidong <cyd@stupidchicken.com> | 23 | 2009-09-19 Chong Yidong <cyd@stupidchicken.com> |
| 19 | 24 | ||
| 20 | * emacs-lisp/advice.el (ad-get-argument, ad-set-argument): Doc | 25 | * emacs-lisp/advice.el (ad-get-argument, ad-set-argument): |
| 21 | fix (Bug#3932). | 26 | Doc fix (Bug#3932). |
| 22 | 27 | ||
| 23 | * subr.el (baud-rate): Remove long-obsolete function (Bug#4372). | 28 | * subr.el (baud-rate): Remove long-obsolete function (Bug#4372). |
| 24 | 29 | ||
| @@ -26,8 +31,8 @@ | |||
| 26 | (time-stamp-dd/mm/yyyy, time-stamp-mon-dd-yyyy) | 31 | (time-stamp-dd/mm/yyyy, time-stamp-mon-dd-yyyy) |
| 27 | (time-stamp-dd-mon-yy, time-stamp-yy/mm/dd) | 32 | (time-stamp-dd-mon-yy, time-stamp-yy/mm/dd) |
| 28 | (time-stamp-yyyy/mm/dd, time-stamp-yyyy-mm-dd) | 33 | (time-stamp-yyyy/mm/dd, time-stamp-yyyy-mm-dd) |
| 29 | (time-stamp-yymmdd, time-stamp-hh:mm:ss, time-stamp-hhmm): Remove | 34 | (time-stamp-yymmdd, time-stamp-hh:mm:ss, time-stamp-hhmm): |
| 30 | functions that have been obsolete since 1995 (Bug#4436). | 35 | Remove functions that have been obsolete since 1995 (Bug#4436). |
| 31 | 36 | ||
| 32 | * progmodes/sh-script.el (sh-learn-buffer-indent): Pop to the | 37 | * progmodes/sh-script.el (sh-learn-buffer-indent): Pop to the |
| 33 | indent buffer only if called interactively (Bug#4452). | 38 | indent buffer only if called interactively (Bug#4452). |
diff --git a/lisp/bookmark.el b/lisp/bookmark.el index debfac03140..bd8511cda71 100644 --- a/lisp/bookmark.el +++ b/lisp/bookmark.el | |||
| @@ -1301,7 +1301,12 @@ for a file, defaulting to the file defined by variable | |||
| 1301 | (let ((print-length nil) | 1301 | (let ((print-length nil) |
| 1302 | (print-level nil)) | 1302 | (print-level nil)) |
| 1303 | (bookmark-insert-file-format-version-stamp) | 1303 | (bookmark-insert-file-format-version-stamp) |
| 1304 | (pp bookmark-alist (current-buffer)) | 1304 | (insert "(") |
| 1305 | ;; Rather than a single call to `pp' we make one per bookmark. | ||
| 1306 | ;; Apparently `pp' has a poor algorithmic complexity, so this | ||
| 1307 | ;; scales a lot better. bug#4485. | ||
| 1308 | (dolist (i bookmark-alist) (pp i (current-buffer))) | ||
| 1309 | (insert ")") | ||
| 1305 | (let ((version-control | 1310 | (let ((version-control |
| 1306 | (cond | 1311 | (cond |
| 1307 | ((null bookmark-version-control) nil) | 1312 | ((null bookmark-version-control) nil) |