From 8e2b7c11b4a18b446201e085b0fdbf293c271c26 Mon Sep 17 00:00:00 2001
From: Benedikt Rascher-Friesenhausen
 <benediktrascherfriesenhausen+git@gmail.com>
Date: Sun, 7 Oct 2018 17:40:30 +0200
Subject: [PATCH] Replace `i32` with `c_int` in `memcmp`

As per the comments from jD91mZM2 on the merge request.
---
 src/header/string/mod.rs | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/header/string/mod.rs b/src/header/string/mod.rs
index 0efe60f8..497a2bbe 100644
--- a/src/header/string/mod.rs
+++ b/src/header/string/mod.rs
@@ -82,7 +82,7 @@ pub unsafe extern "C" fn memcmp(s1: *const c_void, s2: *const c_void, n: usize)
                 let c = *(a as *const u8).offset(i as isize);
                 let d = *(b as *const u8).offset(i as isize);
                 if c != d {
-                    return c as i32 - d as i32;
+                    return c as c_int - d as c_int;
                 }
             }
             unreachable!()
@@ -95,7 +95,7 @@ pub unsafe extern "C" fn memcmp(s1: *const c_void, s2: *const c_void, n: usize)
     let mut b = b as *const u8;
     for _ in 0..rem {
         if *a != *b {
-            return a as i32 - b as i32;
+            return a as c_int - b as c_int;
         }
         a = a.offset(1);
         b = b.offset(1);
-- 
GitLab