diff options
author | Edward Thomson <ethomson@edwardthomson.com> | 2019-01-20 20:30:42 +0000 |
---|---|---|
committer | Edward Thomson <ethomson@edwardthomson.com> | 2019-01-25 22:31:01 +0000 |
commit | 759502ed30574d177b00997e106be22875ad9bd5 (patch) | |
tree | 73f3fa4642b8df6f88bd671522736f461e7d1292 | |
parent | 80c3867b760a8e07d563ef08d47e47ad0a07bcd3 (diff) | |
download | libgit2-759502ed30574d177b00997e106be22875ad9bd5.tar.gz |
odb_loose: explicitly cast to size_t
Quiet down a warning from MSVC about how we're potentially losing data.
This is safe since we've explicitly tested that it's positive and less
than SIZE_MAX.
-rw-r--r-- | src/odb_loose.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/odb_loose.c b/src/odb_loose.c index 649bc56cb..5bdf884d3 100644 --- a/src/odb_loose.c +++ b/src/odb_loose.c @@ -183,7 +183,7 @@ static int parse_header( return -1; } - out->size = size; + out->size = (size_t)size; if (GIT_ADD_SIZET_OVERFLOW(out_len, i, 1)) goto on_error; |