Files
git/builtin
Jeff King 892e723afd do not check odb_mkstemp return value for errors
The odb_mkstemp function does not return an error; it dies
on failure instead. But many of its callers compare the
resulting descriptor against -1 and die themselves.

Mostly this is just pointless, but it does raise a question
when looking at the callers: if they show the results of the
"template" buffer after a failure, what's in it? The answer
is: it doesn't matter, because it cannot happen.

So let's make that clear by removing the bogus error checks.
In bitmap_writer_finish(), we can drop the error-handling
code entirely. In the other two cases, it's shared with the
open() in another code path; we can just move the
error-check next to that open() call.

And while we're at it, let's flesh out the function's
docstring a bit to make the error behavior clear.

Signed-off-by: Jeff King <peff@peff.net>
2017-03-28 15:28:04 -07:00
..
2016-11-22 13:55:20 -08:00
2017-03-17 13:50:24 -07:00
2017-03-17 13:50:25 -07:00
2017-03-17 13:50:25 -07:00
2017-01-30 14:17:00 -08:00
2017-03-17 13:50:23 -07:00
2017-03-17 13:50:25 -07:00
2016-09-29 15:42:18 -07:00
2017-01-18 15:12:15 -08:00
2017-03-17 13:50:25 -07:00
2017-01-31 13:14:56 -08:00
2017-03-17 13:50:25 -07:00
2015-10-05 13:20:08 -07:00
2017-03-27 10:59:26 -07:00
2017-03-22 15:41:21 -07:00
2017-03-24 13:07:37 -07:00
2017-01-23 18:51:56 -08:00