aboutsummaryrefslogtreecommitdiffstats
path: root/man3/libsimple_memelemscan_inv.3
diff options
context:
space:
mode:
Diffstat (limited to 'man3/libsimple_memelemscan_inv.3')
-rw-r--r--man3/libsimple_memelemscan_inv.316
1 files changed, 8 insertions, 8 deletions
diff --git a/man3/libsimple_memelemscan_inv.3 b/man3/libsimple_memelemscan_inv.3
index 77f7119..3fdd8f8 100644
--- a/man3/libsimple_memelemscan_inv.3
+++ b/man3/libsimple_memelemscan_inv.3
@@ -1,11 +1,11 @@
-.TH LIBSIMPLE_MEMELEMSCAN_INV 3 2018-11-24 libsimple
+.TH LIBSIMPLE_MEMELEMSCAN_INV 3 2018-11-25 libsimple
.SH NAME
libsimple_memelemscan_inv \- skip aligned byte string in memory
.SH SYNOPSIS
.nf
#include <libsimple.h>
-void *libsimple_memelemscan_inv(const void *\fIhaystack\fP, size_t \fInhaystack\fP, const void *\fIneedle\fP, size_t \fInneedle\fP);
+void *libsimple_memelemscan_inv(const void *\fIhaystack\fP, const void *\fIneedle\fP, size_t \fIwidth\fP, size_t \fIn\fP);
#ifndef memelemscan_inv
# define memelemscan_inv libsimple_memelemscan_inv
@@ -20,14 +20,14 @@ The
function scans the memory segment
.IR haystack ,
with the size
-.IR nhaystack*nneedle ,
+.IR n*width ,
for the first occurence of a byte string
different from
.I needle
with the size
-.IR nneedle ,
+.IR width ,
and with an offset equivalent to zero modulo
-.IR nneedle .
+.IR width .
If no such character exist in the memory
segment, the memory segment's end is returned.
.PP
@@ -38,14 +38,14 @@ The
function returns the pointer
.I s
with a minimal offset such that
-.IR memcmp(r,needle,nneedle) ,
+.IR memcmp(r,needle,width) ,
where
.I r
is the returned pointer, and such that
the offset is equivalent to zero modulo
-.IR nneedle .
+.IR width .
If no such offset exists,
-.I (void *)&((char *)haystack)[nhaystack*nneedle]
+.I (void *)&((char *)haystack)[n*width]
is returned.
.SH ERRORS
The