This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] localedef: improve error message [BZ #16985]
- From: Roland McGrath <roland at hack dot frob dot com>
- To: Mike Frysinger <vapier at gentoo dot org>
- Cc: libc-alpha at sourceware dot org
- Date: Fri, 11 Sep 2015 13:27:33 -0700 (PDT)
- Subject: Re: [PATCH] localedef: improve error message [BZ #16985]
- Authentication-results: sourceware.org; auth=none
- References: <1440880793-32082-1-git-send-email-vapier at gentoo dot org> <20150911182429 dot GE640 at vapier>
I'm not following exactly what the case is. It looks to me like the only
cases where construct_output_path can return NULL is when asprintf fails or
when mkdir fails. The asprintf case really should just be an immediate
failure as xmalloc would do. When mkdir fails, I'm not entirely clear on
why we don't just die immediately. I guess the idea is that we can
diagnose input errors even if we will never succeed in writing the output.
I wonder how worthwhile that really is.