Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Chatty little precompiler for _arguments
- X-seq: zsh-workers 8030
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx
- Subject: Re: Chatty little precompiler for _arguments
- Date: Thu, 23 Sep 1999 16:07:21 +0200 (MET DST)
- In-reply-to: Tanaka Akira's message of 23 Sep 1999 22:57:30 +0900
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
Tanaka Akira wrote:
> In article <199909230913.LAA23608@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
> Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx> writes:
>
> > The longest string a character can be quoted to is three characters...
>
> It's not longest, in current implementation at least.
>
> Z:akr@is27e1u11% Src/zsh -f
> is27e1u11% a="'''''''''''"
> is27e1u11% print -lr - ${(qq)a}
> zsh: segmentation fault (core dumped) Src/zsh -f
> Z:akr@is27e1u11%
Ouch.
Bye
Sven
--- os/utils.c Thu Sep 23 12:30:20 1999
+++ Src/utils.c Thu Sep 23 16:05:22 1999
@@ -2976,7 +2976,7 @@
{
const char *u, *tt;
char *v;
- char *buf = ncalloc(3 * strlen(s) + 1);
+ char *buf = ncalloc(4 * strlen(s) + 1);
int sf = 0;
tt = v = buf;
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author