* zle_refresh patch - also see next message
@ 1996-11-13 12:54 Geoff Wing
0 siblings, 0 replies; only message in thread
From: Geoff Wing @ 1996-11-13 12:54 UTC (permalink / raw)
To: zsh-workers
Heyla,
this adds a bit more checking - hopefully unnecessary.
It's built on my previous patches zsh-workers/{2336,2351,2359}
The message following this contains a bug fix for a stupid bug that have
been causing some people trouble.
*** zle_refresh.c.~3~ Sun Nov 10 16:01:03 1996
--- zle_refresh.c Wed Nov 13 23:50:34 1996
***************
*** 596,614 ****
if (nbuf[vln] && *nbuf[vln])
zputc(*nbuf[vln], shout);
else
! zputc(' ', shout); /* I don't think this should happen */
! nl++;
! if (*ol)
! ol++;
! ccs = 1;
}
/* 2c: if we're on the first line, start checking at the end of the prompt;
we shouldn't be doing anything within the prompt */
if (ln == 0 && pptw) {
! nl += (pptw - ccs);
! ol += (pptw - ccs);
ccs = pptw;
}
--- 596,618 ----
if (nbuf[vln] && *nbuf[vln])
zputc(*nbuf[vln], shout);
else
! zputc(' ', shout); /* I don't think this should happen */
! if (ln == vln) { /* better safe than sorry */
! nl++;
! if (*ol)
! ol++;
! ccs = 1;
! } /* else hmmm... I wonder what happened */
}
/* 2c: if we're on the first line, start checking at the end of the prompt;
we shouldn't be doing anything within the prompt */
if (ln == 0 && pptw) {
! i = pptw - ccs;
! j = strlen(ol);
! nl += i;
! ol += (i > j ? j : i); /* if ol is too short, point it to '\0' */
ccs = pptw;
}
***************
*** 653,659 ****
we can do, so we just dump out what we must and clear if we can */
if (!*ol) {
i = (col_cleareol >= 0) ? col_cleareol : nllen;
! i -= ccs;
zwrite(nl, i, 1, shout);
vcs += i;
if (col_cleareol >= 0)
--- 657,663 ----
we can do, so we just dump out what we must and clear if we can */
if (!*ol) {
i = (col_cleareol >= 0) ? col_cleareol : nllen;
! i -= vcs;
zwrite(nl, i, 1, shout);
vcs += i;
if (col_cleareol >= 0)
--
Geoff Wing [gwing@primenet.com.au] Technical Manager
Phone : +61-3-9818 2977 PrimeNet - Internet Consultancy
Facsimile: +61-3-9819 3788 Web : <URL:http://www.primenet.com.au/>
Mobile : 0412 162 441
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1996-11-13 13:09 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1996-11-13 12:54 zle_refresh patch - also see next message Geoff Wing
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).