diff options
| author | Gerd Moellmann | 2000-12-11 15:33:34 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2000-12-11 15:33:34 +0000 |
| commit | ab7e20d586cae93a2f763ca54aa5273926cb894a (patch) | |
| tree | 9991361bba1a38dda4d452f083ec3b1fb817c256 | |
| parent | 6e80fddb98809ae5b527e26e585186400c60e88f (diff) | |
| download | emacs-ab7e20d586cae93a2f763ca54aa5273926cb894a.tar.gz emacs-ab7e20d586cae93a2f763ca54aa5273926cb894a.zip | |
(kill-new): Don't try to setcar kill-ring if it is
nil.
| -rw-r--r-- | lisp/simple.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/simple.el b/lisp/simple.el index 2158d35891c..aded4e0650d 100644 --- a/lisp/simple.el +++ b/lisp/simple.el | |||
| @@ -1668,7 +1668,7 @@ Optional second argument REPLACE non-nil means that STRING will replace | |||
| 1668 | the front of the kill ring, rather than being added to the list." | 1668 | the front of the kill ring, rather than being added to the list." |
| 1669 | (and (fboundp 'menu-bar-update-yank-menu) | 1669 | (and (fboundp 'menu-bar-update-yank-menu) |
| 1670 | (menu-bar-update-yank-menu string (and replace (car kill-ring)))) | 1670 | (menu-bar-update-yank-menu string (and replace (car kill-ring)))) |
| 1671 | (if replace | 1671 | (if (and replace kill-ring) |
| 1672 | (setcar kill-ring string) | 1672 | (setcar kill-ring string) |
| 1673 | (setq kill-ring (cons string kill-ring)) | 1673 | (setq kill-ring (cons string kill-ring)) |
| 1674 | (if (> (length kill-ring) kill-ring-max) | 1674 | (if (> (length kill-ring) kill-ring-max) |