about summary refs log tree commit diff
path: root/libtokencap
diff options
context:
space:
mode:
Diffstat (limited to 'libtokencap')
-rw-r--r--libtokencap/Makefile4
-rw-r--r--libtokencap/libtokencap.so.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/libtokencap/Makefile b/libtokencap/Makefile
index 244ee58f..2343125f 100644
--- a/libtokencap/Makefile
+++ b/libtokencap/Makefile
@@ -16,7 +16,7 @@
 PREFIX      ?= /usr/local
 HELPER_PATH  = $(PREFIX)/lib/afl
 DOC_PATH    ?= $(PREFIX)/share/doc/afl
-MAN_PATH    ?= $(PREFIX)/man/man8
+MAN_PATH    ?= $(PREFIX)/share/man/man8
 
 VERSION     = $(shell grep '^\#define VERSION ' ../config.h | cut -d '"' -f2)
 
@@ -70,7 +70,7 @@ all: $(TARGETS)
 
 VPATH = ..
 libtokencap.so: libtokencap.so.c ../config.h
-	$(CC) $(CFLAGS) -shared -fPIC $< -o ../$@ $(LDFLAGS)
+	$(CC) $(CFLAGS) $(CPPFLAGS) -shared -fPIC $< -o ../$@ $(LDFLAGS)
 
 .NOTPARALLEL: clean
 
diff --git a/libtokencap/libtokencap.so.c b/libtokencap/libtokencap.so.c
index 21bac082..3629e804 100644
--- a/libtokencap/libtokencap.so.c
+++ b/libtokencap/libtokencap.so.c
@@ -275,8 +275,8 @@ static void __tokencap_load_mappings(void) {
 
   for (c = map; r > 0; c++, r -= sizeof(prmap_t)) {
 
-    __tokencap_ro[__tokencap_ro_cnt].st = c->pr_vaddr;
-    __tokencap_ro[__tokencap_ro_cnt].en = c->pr_vaddr + c->pr_size;
+    __tokencap_ro[__tokencap_ro_cnt].st = (void *)c->pr_vaddr;
+    __tokencap_ro[__tokencap_ro_cnt].en = (void *)(c->pr_vaddr + c->pr_size);
 
     if (++__tokencap_ro_cnt == MAX_MAPPINGS) break;