From: Lee <ler762@gmail.com>
To: Thomas Wolff <towo@towo.net>
Cc: cygwin@cygwin.com
Subject: Re: Incompatible clipboard format between 32bit and 64bit cygwin
Date: Sun, 26 Sep 2021 15:09:08 -0400 [thread overview]
Message-ID: <CAD8GWsvZP00wAW_UTQ3O3PDhiJvdf2KxPabaaynGU_LfD30u8w@mail.gmail.com> (raw)
In-Reply-To: <dd433ab8-ca9b-d6e8-3dce-c69a4dc9c593@towo.net>
On 9/26/21, Thomas Wolff wrote:
>
> Am 26.09.2021 um 20:37 schrieb Thomas Wolff:
>>
>> Am 26.09.2021 um 11:50 schrieb Mark Geisert:
>>> Hi Takashi,
>>>
>>> Takashi Yano via Cygwin wrote:
>>>> I noticed that cygwin clipboard is not compatible
>>>> between 32bit and 64bit cygwin.
>>>>
>>>> If I run 'echo AAAAAAAA > /dev/clipboard' in 32bit cygwin,
>>>> and run 'cat /dev/clipboard' in 64bit cygwin, this result in
>>>> cat: /dev/clipboard: Bad address
>>>>
>>>> This is because the structure
>>>> typedef struct
>>>> {
>>>> timestruc_t timestamp;
>>>> size_t len;
>>>> char data[1];
>>>> } cygcb_t;
>>>> defined in fhandler_clipboard.cc has different size.
>>>>
>>>> Is this the known issue?
>>>
>>> I doubt anybody has ever tried what you did.
>> I have and it failed; I just didn't find it important enough to report
>> it here... Thanks for the plan to fix it.
>>
>>> I have been testing getclip and putclip between 32- and 64-bit
>>> environments, but neglected to test Cygwin-internal clipboard format
>>> that prepends cygcb_t to the user-supplied data.
> As we're at it, what's the purpose of a cygwin-internal clipboard format
> at all?
speed?
Maybe I'm not understanding the question, but I put a question to this
list ~3 years ago about right-click/paste into a mintty window being
**really** slow and the answer was to use getclip:
$ time d2u < /dev/clipboard > hosts-3.txt
real 0m11.372s
user 0m3.749s
sys 0m6.984s
$ time cat /dev/clipboard | tr -d '\r' > hosts-2.txt
real 0m4.405s
user 0m0.124s
sys 0m3.577s
$ time getclip -u > hosts.txt
real 0m0.734s
user 0m0.031s
sys 0m0.031s
Lee
next prev parent reply other threads:[~2021-09-26 19:09 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-26 1:33 Takashi Yano
2021-09-26 9:50 ` Mark Geisert
2021-09-26 18:37 ` Thomas Wolff
2021-09-26 18:41 ` Thomas Wolff
2021-09-26 19:09 ` Lee [this message]
2021-09-26 20:46 ` Brian Inglis
2021-09-28 4:49 ` Mark Geisert
2021-09-28 5:22 ` Brian Inglis
2021-09-28 6:19 ` Takashi Yano
2021-09-28 6:46 ` Brian Inglis
2021-09-28 8:13 ` Takashi Yano
2021-09-28 17:11 ` Mark Geisert
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=CAD8GWsvZP00wAW_UTQ3O3PDhiJvdf2KxPabaaynGU_LfD30u8w@mail.gmail.com \
--to=ler762@gmail.com \
--cc=cygwin@cygwin.com \
--cc=towo@towo.net \
/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.
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).