Skip to content

Commit 6c223e4

Browse files
pcloudsgitster
authored andcommitted
fast-import.c: use error_errno()
Signed-off-by: Nguyễn Thái Ngọc Duy <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent e1ebb3c commit 6c223e4

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

fast-import.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -414,7 +414,7 @@ static void write_crash_report(const char *err)
414414
struct recent_command *rc;
415415

416416
if (!rpt) {
417-
error("can't write crash report %s: %s", loc, strerror(errno));
417+
error_errno("can't write crash report %s", loc);
418418
free(loc);
419419
return;
420420
}
@@ -1806,8 +1806,8 @@ static void dump_marks(void)
18061806
return;
18071807

18081808
if (hold_lock_file_for_update(&mark_lock, export_marks_file, 0) < 0) {
1809-
failure |= error("Unable to write marks file %s: %s",
1810-
export_marks_file, strerror(errno));
1809+
failure |= error_errno("Unable to write marks file %s",
1810+
export_marks_file);
18111811
return;
18121812
}
18131813

@@ -1822,8 +1822,8 @@ static void dump_marks(void)
18221822

18231823
dump_marks_helper(f, 0, marks);
18241824
if (commit_lock_file(&mark_lock)) {
1825-
failure |= error("Unable to write file %s: %s",
1826-
export_marks_file, strerror(errno));
1825+
failure |= error_errno("Unable to write file %s",
1826+
export_marks_file);
18271827
return;
18281828
}
18291829
}

0 commit comments

Comments
 (0)