Commit 824f4acd by Vicent Marti

Fix redeclaration warnings in MSVC

Signed-off-by: Vicent Marti <tanoku@gmail.com>
parent f8b422b6
...@@ -20,6 +20,9 @@ typedef __int64 off64_t; ...@@ -20,6 +20,9 @@ typedef __int64 off64_t;
# define S_ISREG(m) (((m) & _S_IFMT) == _S_IFREG) # define S_ISREG(m) (((m) & _S_IFMT) == _S_IFREG)
# define S_ISFIFO(m) (((m) & _S_IFMT) == _S_IFIFO) # define S_ISFIFO(m) (((m) & _S_IFMT) == _S_IFIFO)
#if (_MSC_VER >= 1600)
# include <stdint.h>
#else
/* add some missing <stdint.h> typedef's */ /* add some missing <stdint.h> typedef's */
typedef signed char int8_t; typedef signed char int8_t;
typedef unsigned char uint8_t; typedef unsigned char uint8_t;
...@@ -35,6 +38,7 @@ typedef unsigned long long uint64_t; ...@@ -35,6 +38,7 @@ typedef unsigned long long uint64_t;
typedef long long intmax_t; typedef long long intmax_t;
typedef unsigned long long uintmax_t; typedef unsigned long long uintmax_t;
#endif
#endif #endif
......
...@@ -1435,7 +1435,7 @@ static int unpack_object(git_rawobj *out, git_pack *p, index_entry *e) ...@@ -1435,7 +1435,7 @@ static int unpack_object(git_rawobj *out, git_pack *p, index_entry *e)
deflated_size = (size_t)e->size; deflated_size = (size_t)e->size;
if (deflated_size == 0) if (deflated_size == 0)
deflated_size = p->pack_size - e->offset; deflated_size = (size_t)(p->pack_size - e->offset);
byte = *buffer++ & 0xFF; byte = *buffer++ & 0xFF;
deflated_size--; deflated_size--;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment