summaryrefslogtreecommitdiff
path: root/src/oid.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/oid.c')
-rw-r--r--src/oid.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/oid.c b/src/oid.c
index a70b7e099..d56b6af24 100644
--- a/src/oid.c
+++ b/src/oid.c
@@ -211,7 +211,7 @@ int git_oid_strcmp(const git_oid *oid_a, const char *str)
for (a = oid_a->id; *str && (a - oid_a->id) < GIT_OID_RAWSZ; ++a) {
if ((hexval = git__fromhex(*str++)) < 0)
return -1;
- strval = hexval << 4;
+ strval = (unsigned char)(hexval << 4);
if (*str) {
if ((hexval = git__fromhex(*str++)) < 0)
return -1;