summaryrefslogtreecommitdiff
path: root/util.h
diff options
context:
space:
mode:
Diffstat (limited to 'util.h')
-rw-r--r--util.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/util.h b/util.h
index 3a74bd02bd..8f4171bebc 100644
--- a/util.h
+++ b/util.h
@@ -231,6 +231,11 @@ means arg not present, 1 is empty string/null byte */
#define instr(haystack, needle) strstr(haystack, needle)
+#ifdef HAS_MEMMEM
+# define ninstr(big, bigend, little, lend) \
+ ((char *) memmem(big, bigend - big, little, lend - little))
+#endif
+
/*
* ex: set ts=8 sts=4 sw=4 et:
*/