integer: use int64_t's for checks Use int64_t internally for type visibility.
diff --git a/src/integer.h b/src/integer.h
index e024a86..067c0be 100644
--- a/src/integer.h
+++ b/src/integer.h
@@ -8,10 +8,10 @@
#define INCLUDE_integer_h__
/** @return true if p fits into the range of a size_t */
-GIT_INLINE(int) git__is_sizet(git_off_t p)
+GIT_INLINE(int) git__is_sizet(int64_t p)
{
size_t r = (size_t)p;
- return p == (git_off_t)r;
+ return p == (int64_t)r;
}
/** @return true if p fits into the range of an ssize_t */
@@ -36,10 +36,10 @@ GIT_INLINE(int) git__is_uint32(size_t p)
}
/** @return true if p fits into the range of an unsigned long */
-GIT_INLINE(int) git__is_ulong(git_off_t p)
+GIT_INLINE(int) git__is_ulong(int64_t p)
{
unsigned long r = (unsigned long)p;
- return p == (git_off_t)r;
+ return p == (int64_t)r;
}
/** @return true if p fits into the range of an int */