diff options
Diffstat (limited to 'src/filebuf.c')
| -rw-r--r-- | src/filebuf.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/filebuf.c b/src/filebuf.c index 8b3ebb3e2..cfc8528e6 100644 --- a/src/filebuf.c +++ b/src/filebuf.c @@ -50,6 +50,7 @@ static int lock_file(git_filebuf *file, int flags) if (flags & GIT_FILEBUF_FORCE) p_unlink(file->path_lock); else { + giterr_clear(); /* actual OS error code just confuses */ giterr_set(GITERR_OS, "Failed to lock file '%s' for writing", file->path_lock); return -1; |
