From: Stephane Chazelas <Stephane_Chazelas@yahoo.fr>
To: zsh-workers@sunsite.dk
Subject: Re: Pasting of long lines to ZLE is buggy under Mac OS X
Date: Thu, 2 Oct 2008 09:17:58 +0100 [thread overview]
Message-ID: <20081002081758.GA5772@sc.homeunix.net> (raw)
In-Reply-To: <20081002065525.GR24822@prunille.vinc17.org>
On Thu, Oct 02, 2008 at 08:55:25AM +0200, Vincent Lefevre wrote:
> It seems that zsh 4.3.6 suffers from a buffering problem when pasting
> long lines under Mac OS X (at least 10.4.11). Other software, such as
> bash and emacs (running in a terminal), does not seem to have such a
> problem.
[...]
You may want to try "strace" or "truss" or the equivalent on
your system.
Here (4.3.6-dev-0+0925), it seems zsh reads one character at a time, and for
every character, surprisingly, it does:
read(10, "."..., 1) = 1
fcntl64(0, F_DUPFD, 10) = 11
close(0) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [CHLD], 8) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [CHLD], 8) = 0
rt_sigprocmask(SIG_UNBLOCK, [CHLD], [CHLD], 8) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
rt_sigprocmask(SIG_UNBLOCK, [CHLD], [CHLD], 8) = 0
dup2(11, 0) = 0
close(11) = 0
write(10, "."..., 1.) = 1
It doesn't do that on another machine with 4.3.6-dev-0+0925
(debian x86 as well) where it just does:
read(10, "f"..., 1) = 1
write(10, "f"..., 1f) = 1
But if zsh reads one character at a time, it's difficult to
explain how big copy pastes cause problems.
--
Stéphane
next prev parent reply other threads:[~2008-10-02 8:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-02 6:55 Vincent Lefevre
2008-10-02 8:17 ` Stephane Chazelas [this message]
2008-10-02 15:36 ` Bart Schaefer
2008-10-03 8:36 ` Vincent Lefevre
2008-10-16 5:57 ` Bart Schaefer
2008-10-19 22:18 ` Vincent Lefevre
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=20081002081758.GA5772@sc.homeunix.net \
--to=stephane_chazelas@yahoo.fr \
--cc=zsh-workers@sunsite.dk \
/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.vuxu.org/mirror/zsh/
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 NNTP newsgroup(s).