From: Luc Teirlinck <teirllm@dms.auburn.edu>
Cc: emacs-pretest-bug@gnu.org, emacs-devel@gnu.org
Subject: Re: error when tty-coding-system is utf-8
Date: Thu, 2 Jun 2005 17:41:11 -0500 (CDT) [thread overview]
Message-ID: <200506022241.j52MfBi02931@raven.dms.auburn.edu> (raw)
In-Reply-To: <871x7k7b1w.fsf@tc-1-100.kawasaki.gol.ne.jp> (message from Miles Bader on Fri, 03 Jun 2005 05:34:19 +0900)
Is gnus-start-date-timer running when your problem occurs?
It runs article-update-date-lapsed which conducts a regexp search
without saving and restoring the match data, as it should.
I believe that the patch below is necessary, _regardless_ of whether
it solves your problem. Does it? There may be other similar problems
in gnus or elsewhere. I could install the patch, if desired. An
alternative is to automatically restore the match data around _all_
timers, but Richard pointed out that this would lead to
inefficiencies.
===File ~/gnus-art-diff=====================================
*** gnus-art.el 01 Jun 2005 10:13:45 -0500 1.74
--- gnus-art.el 02 Jun 2005 17:21:40 -0500
***************
*** 3034,3053 ****
(defun article-update-date-lapsed ()
"Function to be run from a timer to update the lapsed time line."
! (let (deactivate-mark)
! (save-excursion
! (ignore-errors
! (walk-windows
! (lambda (w)
! (set-buffer (window-buffer w))
! (when (eq major-mode 'gnus-article-mode)
! (let ((mark (point-marker)))
! (goto-char (point-min))
! (when (re-search-forward "^X-Sent:" nil t)
! (article-date-lapsed t))
! (goto-char (marker-position mark))
! (move-marker mark nil))))
! nil 'visible)))))
(defun gnus-start-date-timer (&optional n)
"Start a timer to update the X-Sent header in the article buffers.
--- 3034,3054 ----
(defun article-update-date-lapsed ()
"Function to be run from a timer to update the lapsed time line."
! (save-match-data
! (let (deactivate-mark)
! (save-excursion
! (ignore-errors
! (walk-windows
! (lambda (w)
! (set-buffer (window-buffer w))
! (when (eq major-mode 'gnus-article-mode)
! (let ((mark (point-marker)))
! (goto-char (point-min))
! (when (re-search-forward "^X-Sent:" nil t)
! (article-date-lapsed t))
! (goto-char (marker-position mark))
! (move-marker mark nil))))
! nil 'visible))))))
(defun gnus-start-date-timer (&optional n)
"Start a timer to update the X-Sent header in the article buffers.
============================================================
next prev parent reply other threads:[~2005-06-02 22:41 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-02 20:34 error when tty-coding-system is utf-8 Miles Bader
2005-06-02 21:19 ` Luc Teirlinck
2005-06-02 22:41 ` Luc Teirlinck [this message]
2005-06-03 4:48 ` Stefan Monnier
2005-06-03 0:12 ` Luc Teirlinck
2005-06-03 0:21 ` Miles Bader
2005-06-03 1:02 ` Luc Teirlinck
2005-06-03 1:15 ` Luc Teirlinck
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200506022241.j52MfBi02931@raven.dms.auburn.edu \
--to=teirllm@dms.auburn.edu \
--cc=emacs-devel@gnu.org \
--cc=emacs-pretest-bug@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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).