Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: PATCH: more zle fixes
- X-seq: zsh-workers 20855
- From: Andrey Borzenkov <arvidjaar@xxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: Re: PATCH: more zle fixes
- Date: Wed, 23 Feb 2005 16:42:45 +0300
- In-reply-to: <200502231305.j1ND5p6F030160@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <200502231305.j1ND5p6F030160@xxxxxxxxxxxxxx>
On Wednesday 23 February 2005 16:05, Peter Stephenson wrote:
> + char s[MB_CUR_MAX+1];
MB_CUR_MAX is not required to be constant so the above may well be invalid on
non-GCC.
conversion from wc to mb may require extra space for shift characters above
MB_CUR_MAX. Completely bulletproof solution must check for resulting length
and allocate buffer that is needed. Unfortunately it is not quite clear how
to check length; wctomb(0, ...) does not return length, instead resets
internal state.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author