File: byte_diff.3

package info (click to toggle)
libowfat 0.34-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,288 kB
  • sloc: ansic: 20,181; makefile: 16
file content (18 lines) | stat: -rw-r--r-- 586 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
.TH byte_diff 3
.SH NAME
byte_diff \- compare two strings
.SH SYNTAX
.B #include <libowfat/byte.h>

int \fBbyte_diff\fP(const char *\fIone\fR,size_t \fIlen\fR,const char *\fItwo\fR);
.SH DESCRIPTION
\fIbyte_diff\fR returns negative, 0, or positive, depending on whether
the string \fIone\fR[0], \fIone\fR[1], ..., \fIone\fR[\fIlen\fR-1] is
lexicographically smaller than, equal to, or greater than the string
\fIone\fR[0], \fIone\fR[1], ..., \fIone\fR[\fIlen\fR-1].

When the strings are different, byte_diff does not read bytes past the
first difference.

.SH "SEE ALSO"
byte_equal(3)