From: Junio C Hamano Date: Sun, 07 Jun 2009 16:57:04 GMT Subject: Re: [PATCH v2 1/3] Introduce die_errno() that appends strerror(errno) to die() Message-ID: <7vzlck9e3j.fsf@alter.siamese.dyndns.org> In-Reply-To: <2325a7950906070412k3a440558h35db7511cc390e4b@mail.gmail.com> Alexander Potashev writes: > This breaks theoretical usage of custom format string in custom die > routines: > 1. A custom die routine might not support %s. > 2. If the die routine adds a custom format specifier, vsnprintf > will fail. I do not think that flies even as a theory. The "custom" 39a3f5ea talks about is more about "Instead of sending it to stderr, let's pop up an info window and give the message there" kind of customization. Existing die() that prints errno does so by giving strerror() to "%s", so no matter how custom your die routine is, you must support '%s' for its output to make sense to humans. If you "not support %s", then you will ignore (or choke at) such strerror() result without this patch anyway.