all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: monnier@iro.umontreal.ca, emacs-devel@gnu.org
Subject: Re: master b8062be 3/5: Remove some compat code from eudc-bob.el
Date: Thu, 13 Aug 2020 16:14:48 +0300	[thread overview]
Message-ID: <83imdmn0vr.fsf@gnu.org> (raw)
In-Reply-To: <87mu2zhssl.fsf@gnus.org> (message from Lars Ingebrigtsen on Thu,  13 Aug 2020 10:08:26 +0200)

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Date: Thu, 13 Aug 2020 10:08:26 +0200
> Cc: emacs-devel@gnu.org
> 
> (defun eudc-bob-save-object ()
>   "Save the object data of the button at point."
>   (interactive)
>   (let ((data (eudc-bob-get-overlay-prop 'object-data))
> 	(buffer (generate-new-buffer "*eudc-tmp*")))
>     (save-excursion
>       (set-buffer-file-coding-system 'binary)
>       (set-buffer buffer)
>       (set-buffer-multibyte nil)
>       (insert data)
>       (save-buffer))
>     (kill-buffer buffer)))
> 
> I think the intention here is to change the coding system in this new
> temporary buffer (before saving), and not whatever buffer the caller of
> the function was...

I think we can simply delete the line that sets
buffer-file-coding-system: in a unibyte buffer it doesn't matter
anyway.  (And it's wrong to use 'binary' for producing files that will
be processed by programs other than Emacs, because 'binary' spills out
the Emacs internal representation of characters.)



  reply	other threads:[~2020-08-13 13:14 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20200812175454.4839.92908@vcs0.savannah.gnu.org>
     [not found] ` <20200812175456.C5D122172E@vcs0.savannah.gnu.org>
2020-08-12 17:56   ` master b8062be 3/5: Remove some compat code from eudc-bob.el Lars Ingebrigtsen
2020-08-12 18:15     ` Stefan Monnier
2020-08-13  8:08       ` Lars Ingebrigtsen
2020-08-13 13:14         ` Eli Zaretskii [this message]
2020-08-13 13:58           ` Stefan Monnier
2020-08-13 14:14             ` Eli Zaretskii
2020-08-13 14:23               ` Stefan Monnier
2020-08-13 16:43                 ` Eli Zaretskii
2020-08-13 17:43                   ` Stefan Monnier
2020-08-13 18:25                     ` Eli Zaretskii
2020-08-13 19:02                       ` Stefan Monnier
2020-08-13 19:06                         ` Eli Zaretskii
2020-08-13 19:54                           ` Stefan Monnier
2020-08-14  6:05                             ` Eli Zaretskii
2020-08-14  9:54                               ` Lars Ingebrigtsen
2020-08-14 10:35                                 ` Eli Zaretskii
2020-08-14 11:03                                   ` Eli Zaretskii
2020-08-15  9:53                                     ` Lars Ingebrigtsen
2020-08-15 12:56                                       ` Stefan Monnier
2020-08-15 15:10                                       ` Eli Zaretskii
2020-08-16 11:17                                         ` Lars Ingebrigtsen
2020-08-16 14:41                                           ` Eli Zaretskii
2020-08-17  8:32                                             ` Lars Ingebrigtsen
2020-08-17 13:15                                               ` Stefan Monnier
2020-08-18 14:56                                                 ` Lars Ingebrigtsen
2020-08-18 15:08                                                   ` Eli Zaretskii
2020-08-18 17:02                                                   ` Stefan Monnier
2020-08-19 10:20                                                     ` Lars Ingebrigtsen
2020-08-17 14:17                                               ` Eli Zaretskii
2020-08-13 13:33         ` Stefan Monnier
2020-08-15 21:19         ` Stefan Monnier
2020-08-15 21:27           ` Stefan Monnier

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=83imdmn0vr.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=larsi@gnus.org \
    --cc=monnier@iro.umontreal.ca \
    /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.