summaryrefslogtreecommitdiff
path: root/src/odb_loose.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/odb_loose.c')
-rw-r--r--src/odb_loose.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/odb_loose.c b/src/odb_loose.c
index a3013d3dd..dc9897288 100644
--- a/src/odb_loose.c
+++ b/src/odb_loose.c
@@ -670,7 +670,7 @@ static int loose_backend__stream_fwrite(git_oid *oid, git_odb_stream *_stream)
return git__rethrow(error, "Failed to write loose backend");
stream->finished = 1;
- return git_filebuf_commit_at(&stream->fbuf, final_path);
+ return git_filebuf_commit_at(&stream->fbuf, final_path, GIT_OBJECT_FILE_MODE);
}
static int loose_backend__stream_write(git_odb_stream *_stream, const char *data, size_t len)
@@ -790,7 +790,7 @@ static int loose_backend__write(git_oid *oid, git_odb_backend *_backend, const v
if ((error = git_futils_mkpath2file(final_path, GIT_OBJECT_DIR_MODE)) < GIT_SUCCESS)
goto cleanup;
- return git_filebuf_commit_at(&fbuf, final_path);
+ return git_filebuf_commit_at(&fbuf, final_path, GIT_OBJECT_FILE_MODE);
cleanup:
git_filebuf_cleanup(&fbuf);