From: "Петров Андрей" <an.petrov@pay-lab.ru>
To: Po Lu <luangruo@yahoo.com>
Cc: "55727@debbugs.gnu.org" <55727@debbugs.gnu.org>
Subject: bug#55727: 29.0.50; Incorrect zero symbol transcoding between applications
Date: Mon, 30 May 2022 14:27:43 +0000 [thread overview]
Message-ID: <44c9de3ce35141679ab3c158ae2cfe0e@pay-lab.ru> (raw)
In-Reply-To: <878rqjb0h0.fsf@yahoo.com>
Hi, Po.
OK, You can close the bug then.
Just tell me if Emacs have ready to use solution for passing binary
strings between applications in a form what can be correctly restored
with `read' function. I found that output of `print' also can not be
transferred through application boundary.
С уважением,
Андрей Петров,
программист ООО Инпас-Софт.
________________________________________
От: Po Lu <luangruo@yahoo.com>
Отправлено: 30 мая 2022 г. 18:42:51
Кому: Петров Андрей
Копия: 55727@debbugs.gnu.org
Тема: Re: bug#55727: 29.0.50; Incorrect zero symbol transcoding between applications
Петров Андрей <an.petrov@pay-lab.ru> writes:
> Hello, team!
>
> Please check the following behavior:
>
> 1. Start two instances of emacs -Q.
> 2. Switch to the "*scratch*" buffer of the first one and type the following:
> M-: (insert (format "%S" "000\000000")) [RET]
> You should see "000^@000" string.
> 3. Copy the string into clipboard and paste into the other instance of
> Emacs (which you have started before).
> I get "000\0000" instead of "000\000000"
> 4. Try evaluating inserted text ("000\0000")
> C-c C-e
> I get "000^@0" instead of "000^@000".
>
> It seems that "^@" is transcoded between applications into "\0"
> instead of "\000". If I do the same test inside single instance
> of Emacs I get the correct result.
That's not a bug. Most programs cannot tolerate NUL bytes inside
selection strings, so the Emacs selection converter deliberately
replaces those inside a string with "\0" before sending the string to a
requestor.
When one Emacs instance owns the selection, the contents of the kill
ring are used directly when yanking text, so that conversion doesn't
take place.
next prev parent reply other threads:[~2022-05-30 14:27 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-30 13:08 bug#55727: 29.0.50; Incorrect zero symbol transcoding between applications Петров Андрей
2022-05-30 13:42 ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-05-30 14:27 ` Петров Андрей [this message]
2022-05-30 15:42 ` Eli Zaretskii
2022-05-30 16:23 ` Петров Андрей
2022-05-30 18:09 ` Eli Zaretskii
2022-05-31 0:16 ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-05-30 14:06 ` Eli Zaretskii
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=44c9de3ce35141679ab3c158ae2cfe0e@pay-lab.ru \
--to=an.petrov@pay-lab.ru \
--cc=55727@debbugs.gnu.org \
--cc=luangruo@yahoo.com \
/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.