mirror of
https://git.proxmox.com/git/libgit2
synced 2025-05-09 15:00:04 +00:00
Fix redeclaration warnings in MSVC
Signed-off-by: Vicent Marti <tanoku@gmail.com>
This commit is contained in:
parent
f8b422b6d4
commit
824f4acde2
@ -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;
|
|||||||
|
|
||||||
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)
|
|||||||
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--;
|
||||||
|
Loading…
Reference in New Issue
Block a user