Re: [PATCH] builtin-apply: Show a more descriptive error on failure when opening a patch
- From
Johannes Schindelin <johannes.schindelin@gmx.de>
- Date
- Apr 14, 2008, 14:33 UTC
- Message-ID
- <alpine.DEB.1.00.0804141532390.28504@racer>
- In-Reply-To
- <1208183018-27887-1-git-send-email-albertito@gmail.com>
Hi,
On Mon, 14 Apr 2008, Alberto Bertogli wrote:
Show 5 quoted lines
> + if (fd < 0) {
> + error("can't open patch '%s': %s", arg,
> + strerror(errno));
> + return 1;
> + }Do you absolutely want to retain the curly braces, and have two statements? I would prefer "return error(...)", and if you absolutely insist on a return 1: "return !!error(...)".
Ciao, Dscho