all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Ivan Shmakov <ivan@siamics.net>
To: 16145@debbugs.gnu.org, control@debbugs.gnu.org
Subject: bug#16145: ERC disregards data to be logged when reconnecting
Date: Sun, 05 Oct 2014 11:22:25 +0000	[thread overview]
Message-ID: <877g0e7ocu.fsf@violet.siamics.net> (raw)
In-Reply-To: <87sitvxzl4.fsf@violet.siamics.net> (Ivan Shmakov's message of "Sat, 14 Dec 2013 14:43:35 +0000")

[-- Attachment #1: Type: text/plain, Size: 384 bytes --]

tag 16145 + patch
thanks

	I hereby suggest the patch MIMEd.  (In the same spirit as the
	one for Bug#18599.)

2014-10-05  Ivan Shmakov  <ivan@siamics.net>

	* erc.el (erc-initialize-log-marker): Only initialize
	  erc-last-saved-position if not already a marker.  (Closes
	  #16145.)

-- 
FSF associate member #7257  http://boycottsystemd.org/  … 3013 B6A0 230E 334A

[-- Attachment #2: Type: text/plain, Size: 637 bytes --]

--- a/lisp/erc/erc.el
+++ b/lisp/erc/erc.el
@@ -2052,9 +2052,10 @@ defun erc-initialize-log-marker (buffer)
   "Initialize the `erc-last-saved-position' marker to a sensible position.
 BUFFER is the current buffer."
   (with-current-buffer buffer
-    (setq erc-last-saved-position (make-marker))
-    (move-marker erc-last-saved-position
-                 (1- (marker-position erc-insert-marker)))))
+    (unless (markerp erc-last-saved-position)
+      (setq erc-last-saved-position (make-marker))
+      (move-marker erc-last-saved-position
+                   (1- (marker-position erc-insert-marker))))))
 
 ;; interactive startup
 

  reply	other threads:[~2014-10-05 11:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-14 14:43 bug#16145: ERC disregards data to be logged when reconnecting Ivan Shmakov
2014-10-05 11:22 ` Ivan Shmakov [this message]
2014-11-21 19:31   ` Ivan Shmakov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=877g0e7ocu.fsf@violet.siamics.net \
    --to=ivan@siamics.net \
    --cc=16145@debbugs.gnu.org \
    --cc=control@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.