Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
bisect.c: use die_errno() and warning_errno()
author
Nguyễn Thái Ngọc Duy
<pclouds@gmail.com>
Sun, 8 May 2016 09:47:23 +0000
(16:47 +0700)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 9 May 2016 19:29:08 +0000
(12:29 -0700)
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
bisect.c
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
fd1d672
)
diff --git
a/bisect.c
b/bisect.c
index 7996c2907b0e571578f2ce18095c83c134a503b3..6d93edbcb97382269bd310d38cacd95ce3619091 100644
(file)
--- a/
bisect.c
+++ b/
bisect.c
@@
-860,8
+860,8
@@
static void check_good_are_ancestors_of_bad(const char *prefix, int no_checkout)
/* Create file BISECT_ANCESTORS_OK. */
fd = open(filename, O_CREAT | O_TRUNC | O_WRONLY, 0600);
if (fd < 0)
/* Create file BISECT_ANCESTORS_OK. */
fd = open(filename, O_CREAT | O_TRUNC | O_WRONLY, 0600);
if (fd < 0)
- warning
("could not create file '%s': %s
",
-
filename, strerror(errno)
);
+ warning
_errno("could not create file '%s'
",
+
filename
);
else
close(fd);
done:
else
close(fd);
done:
@@
-910,8
+910,7
@@
void read_bisect_terms(const char **read_bad, const char **read_good)
*read_good = "good";
return;
} else {
*read_good = "good";
return;
} else {
- die("could not read file '%s': %s", filename,
- strerror(errno));
+ die_errno("could not read file '%s'", filename);
}
} else {
strbuf_getline_lf(&str, fp);
}
} else {
strbuf_getline_lf(&str, fp);