GNU bug report logs - #54154
29.0.50; [PATCH] `sieve-manage-getscript' fails if script contains multibyte characters

Previous Next

Package: emacs;

Reported by: "Kai Tetzlaff" <kai.tetzlaff <at> t-online.de>

Date: Fri, 25 Feb 2022 09:20:01 UTC

Severity: normal

Tags: patch

Found in version 29.0.50

Fixed in version 29.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #17 received at 54154 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Kai Tetzlaff <kai <at> tetzlaff.eu>
Cc: 54154 <at> debbugs.gnu.org
Subject: Re: bug#54154: 29.0.50; [PATCH] `sieve-manage-getscript' fails if
 script contains multibyte characters
Date: Sat, 26 Feb 2022 16:07:14 +0100
Kai Tetzlaff <kai <at> tetzlaff.eu> writes:

> So just reverting it won't work. I will try to undo the parts relevant
> to this issue.

Sounds good.

> For clarification: The original code before Alberts change was using
> this macro (which seemingly contains an error in the doc string):
>
> (defmacro sieve-manage-disable-multibyte ()
>   "Enable multibyte in the current buffer."
>   (unless (featurep 'xemacs)
>     '(set-buffer-multibyte nil)))
>
> to *disable* multibyte handling in the response/protocol buffer. If
> using `set-buffer-multibyte' is not the right thing, what should be used
> instead?

Using (set-buffer-multibyte nil) is the right thing to do to make a
buffer unibyte -- but usually only when the buffer is empty.  There's
been some discussion about making `set-buffer-multibyte' signal an error
if used in a non-empty buffer, because in 99.7% of the cases where
people do that, it's the wrong thing to do.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




This bug report was last modified 297 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.