summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@edwardthomson.com>2019-06-23 15:16:47 +0100
committerEdward Thomson <ethomson@edwardthomson.com>2019-11-22 15:09:17 +1100
commitbed9fc6b59eafc9ad197a7ff7215ed6be97663ae (patch)
tree8f0ab10bc03df5ef108faf7751a2589663e9b876 /include
parent9b04d0be29caca53a48c683660d1c1ca77de7b02 (diff)
downloadlibgit2-bed9fc6b59eafc9ad197a7ff7215ed6be97663ae.tar.gz
odb: use `git_object_size_t` for object size
Instead of using a signed type (`off_t`) use a new `git_object_size_t` for the sizes of objects.
Diffstat (limited to 'include')
-rw-r--r--include/git2/odb.h2
-rw-r--r--include/git2/odb_backend.h4
2 files changed, 3 insertions, 3 deletions
diff --git a/include/git2/odb.h b/include/git2/odb.h
index e8824b727..c4bfa5290 100644
--- a/include/git2/odb.h
+++ b/include/git2/odb.h
@@ -294,7 +294,7 @@ GIT_EXTERN(int) git_odb_write(git_oid *out, git_odb *odb, const void *data, size
* @param type type of the object that will be written
* @return 0 if the stream was created; error code otherwise
*/
-GIT_EXTERN(int) git_odb_open_wstream(git_odb_stream **out, git_odb *db, git_off_t size, git_object_t type);
+GIT_EXTERN(int) git_odb_open_wstream(git_odb_stream **out, git_odb *db, git_object_size_t size, git_object_t type);
/**
* Write to an odb stream
diff --git a/include/git2/odb_backend.h b/include/git2/odb_backend.h
index 47e0dd4b2..c593bac26 100644
--- a/include/git2/odb_backend.h
+++ b/include/git2/odb_backend.h
@@ -87,8 +87,8 @@ struct git_odb_stream {
unsigned int mode;
void *hash_ctx;
- git_off_t declared_size;
- git_off_t received_bytes;
+ git_object_size_t declared_size;
+ git_object_size_t received_bytes;
/**
* Write at most `len` bytes into `buffer` and advance the stream.