aboutsummaryrefslogtreecommitdiffstats
path: root/memreqlen.c
diff options
context:
space:
mode:
Diffstat (limited to 'memreqlen.c')
-rw-r--r--memreqlen.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/memreqlen.c b/memreqlen.c
index c276b8d..b3cba03 100644
--- a/memreqlen.c
+++ b/memreqlen.c
@@ -1,12 +1,13 @@
/* See LICENSE file for copyright and license details. */
-#include "libsimple.h"
+#include "common.h"
#ifndef TEST
size_t
libsimple_memreqlen(const void *a_, size_t n, const void *b_, size_t m)
{
- const char *a = &((char *)a_)[n], *b = &((char *)b_)[m];
+ const char *a = &((const char *)a_)[n];
+ const char *b = &((const char *)b_)[m];
size_t i = 0, len = n < m ? n : m;
for (; i < len && *--a == *--b; i++);
return i;