From: Peter Stephenson <pws@pwstephenson.fsnet.co.uk>
To: zsh-workers@sunsite.dk
Subject: Re: Vared Using Spaces for characters
Date: Fri, 04 Mar 2005 21:34:37 +0000 [thread overview]
Message-ID: <20050304213439.03E248650@pwstephenson.fsnet.co.uk> (raw)
In-Reply-To: <dc507f4a05030319457b69d4bc@mail.gmail.com>
Felix Rosencrantz wrote:
> % var1=fhardy@boys.com var2=jhardy@boys.com
> % vared var1 ; vared var2
> fhardy@boys.com[]
> j []
This fixes it. I'm not 100% sure we should be using strlen at all, even
in its wide character guise, instead of the lengths of the input
strings.
Index: Src/Zle/zle_refresh.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/Zle/zle_refresh.c,v
retrieving revision 1.21
diff -u -r1.21 zle_refresh.c
--- Src/Zle/zle_refresh.c 25 Feb 2005 15:10:01 -0000 1.21
+++ Src/Zle/zle_refresh.c 4 Mar 2005 21:29:36 -0000
@@ -191,9 +191,15 @@
}
for (ln = 0; ln != winh + 1; ln++) {
if (nbuf[ln])
- *nbuf[ln] = ZWC('\n');
+ {
+ nbuf[ln][0] = ZWC('\n');
+ nbuf[ln][1] = ZWC('\0');
+ }
if (obuf[ln])
- *obuf[ln] = ZWC('\n');
+ {
+ obuf[ln][0] = ZWC('\n');
+ obuf[ln][0] = ZWC('\0');
+ }
}
/* TODO currently zsh core is not using widechars */
--
Peter Stephenson <pws@pwstephenson.fsnet.co.uk>
Work: pws@csr.com
Web: http://www.pwstephenson.fsnet.co.uk
next prev parent reply other threads:[~2005-03-04 21:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-04 3:45 Felix Rosencrantz
2005-03-04 21:34 ` Peter Stephenson [this message]
2005-03-04 22:36 ` Bart Schaefer
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=20050304213439.03E248650@pwstephenson.fsnet.co.uk \
--to=pws@pwstephenson.fsnet.co.uk \
--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).