From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/14453 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Ismael Luceno Newsgroups: gmane.linux.lib.musl.general Subject: Re: [PATCH v2] glob: implement GLOB_TILDE Date: Thu, 25 Jul 2019 17:39:01 +0200 Message-ID: <20190725153901.GA32715@pirotess.home> References: <20190724213338.27138-1-ismael@iodev.co.uk> <20190725034814.GI1506@brightrain.aerifal.cx> <20190725103333.GA30296@pirotess.home> <20190725143024.GL1506@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="152373"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Mutt/1.12.1 (2019-06-15) To: musl@lists.openwall.com Original-X-From: musl-return-14469-gllmg-musl=m.gmane.org@lists.openwall.com Thu Jul 25 17:39:18 2019 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.89) (envelope-from ) id 1hqfpt-000dWe-St for gllmg-musl@m.gmane.org; Thu, 25 Jul 2019 17:39:18 +0200 Original-Received: (qmail 20069 invoked by uid 550); 25 Jul 2019 15:39:14 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 20051 invoked from network); 25 Jul 2019 15:39:14 -0000 Content-Disposition: inline In-Reply-To: <20190725143024.GL1506@brightrain.aerifal.cx> Xref: news.gmane.org gmane.linux.lib.musl.general:14453 Archived-At: On 25/Jul/2019 10:30, Rich Felker wrote: <...> > > I think: > > - ENOMEM should map to NOSPACE. > > - a closer look reveals that all other errors should map to NOMATCH. > > None of the three error codes are really good, but NOMATCH is probably > best. GLOB_ABORTED may be more appropriate with GLOB_ERR set (to allow > application to distinguish between an error processing the glob and > simple nonexistence of matches). Thoughts? Other implementations happily expand to a literal '~', so I guess we could keep things simple and return NOMATCH. -- Ismael Luceno http://iodev.co.uk/