summaryrefslogtreecommitdiff
path: root/lisp/erc/erc-ring.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/erc/erc-ring.el')
-rw-r--r--lisp/erc/erc-ring.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/erc/erc-ring.el b/lisp/erc/erc-ring.el
index 1762700ff36..682585c53bb 100644
--- a/lisp/erc/erc-ring.el
+++ b/lisp/erc/erc-ring.el
@@ -67,7 +67,8 @@ variable.")
(defun erc-input-ring-setup ()
"Do the setup required so that we can use comint style input rings.
Call this function when setting up the mode."
- (setq erc-input-ring (make-ring comint-input-ring-size))
+ (unless (ring-p erc-input-ring)
+ (setq erc-input-ring (make-ring comint-input-ring-size)))
(setq erc-input-ring-index nil))
(defun erc-add-to-input-ring (s)