bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Infinite loop in globbing


From: Chet Ramey
Subject: Re: Infinite loop in globbing
Date: Mon, 14 Mar 2011 13:06:40 -0400

> On 03/14/2011 07:55 AM, Chet Ramey wrote:
> > The question is how to best handle it: punt immediately, or just treat it
> > as a single-byte character and move on.
> 
> I vote single-byte character; after all, it's possible for a filename to
> contain that character, regardless of what your locale may be.

Oh, it does do that.  I meant in the context of attempting to convert the
entire string to a wide-char string.  If the wide-char string conversion
fails, the globbing engine treats it as a sequence of single bytes.  There
are efficiency improvements that can be made there, though.

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]