diff options
author | unknown <Romain@.(none)> | 2011-06-03 19:38:46 +0200 |
---|---|---|
committer | Romain Geissler <romain.geissler@gmail.com> | 2011-06-03 21:03:58 +0200 |
commit | bb88da7f90f23a89ebae58bd90d9859feec84530 (patch) | |
tree | 58528e565dcea66b86b508c5a4e7e0ee62065636 | |
parent | 04fdc10d3581fb58adc2a3a375fdbb5d57774027 (diff) | |
download | libgit2-bb88da7f90f23a89ebae58bd90d9859feec84530.tar.gz |
Sha1Lookup: Fixed two MSVC compilation warnings.
-rw-r--r-- | src/fileops.h | 6 | ||||
-rw-r--r-- | src/sha1_lookup.c | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/fileops.h b/src/fileops.h index 0334bb176..d271f312b 100644 --- a/src/fileops.h +++ b/src/fileops.h @@ -14,10 +14,10 @@ #define GIT_PATH_LIST_SEPARATOR ':' -#ifdef GIT__WIN32 -#define GIT_PLATFORM_PATH_SEP '/' -#else +#ifdef GIT_WIN32 #define GIT_PLATFORM_PATH_SEP '\\' +#else +#define GIT_PLATFORM_PATH_SEP '/' #endif #ifdef GIT_WIN32 diff --git a/src/sha1_lookup.c b/src/sha1_lookup.c index f4a3c42cc..6ac00c5aa 100644 --- a/src/sha1_lookup.c +++ b/src/sha1_lookup.c @@ -97,7 +97,7 @@ int sha1_entry_pos(const void *table, unsigned lo, unsigned hi, unsigned nr, const unsigned char *key) { - const unsigned char *base = table; + const unsigned char *base = (const unsigned char*)table; const unsigned char *hi_key, *lo_key; unsigned ofs_0; @@ -192,5 +192,5 @@ int sha1_entry_pos(const void *table, lo_key = mi_key + elem_size; } } while (lo < hi); - return -lo-1; + return -((int)lo)-1; } |