summaryrefslogtreecommitdiffstats
path: root/man3/strverscmp.3
diff options
context:
space:
mode:
Diffstat (limited to 'man3/strverscmp.3')
-rw-r--r--man3/strverscmp.320
1 files changed, 9 insertions, 11 deletions
diff --git a/man3/strverscmp.3 b/man3/strverscmp.3
index 39d7b20cf..e33a569d3 100644
--- a/man3/strverscmp.3
+++ b/man3/strverscmp.3
@@ -4,7 +4,7 @@
.\"
.\" SPDX-License-Identifier: Linux-man-pages-copyleft
.\"
-.TH strverscmp 3 2022-12-15 "Linux man-pages 6.03"
+.TH strverscmp 3 2023-07-20 "Linux man-pages 6.05.01"
.SH NAME
strverscmp \- compare two version strings
.SH LIBRARY
@@ -74,19 +74,17 @@ or later than
.SH ATTRIBUTES
For an explanation of the terms used in this section, see
.BR attributes (7).
-.ad l
-.nh
.TS
allbox;
lbx lb lb
l l l.
Interface Attribute Value
T{
+.na
+.nh
.BR strverscmp ()
T} Thread safety MT-Safe
.TE
-.hy
-.ad
.sp 1
.\" FIXME: The marking is different from that in the glibc manual,
.\" which has:
@@ -99,7 +97,7 @@ T} Thread safety MT-Safe
.\" we may call isdigit() in macro, then strverscmp() should not have locale
.\" problem.
.SH STANDARDS
-This function is a GNU extension.
+GNU.
.SH EXAMPLES
The program below can be used to demonstrate the behavior of
.BR strverscmp ().
@@ -122,22 +120,22 @@ jan1 < jan10
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-
+\&
int
main(int argc, char *argv[])
{
int res;
-
+\&
if (argc != 3) {
fprintf(stderr, "Usage: %s <string1> <string2>\en", argv[0]);
exit(EXIT_FAILURE);
}
-
+\&
res = strverscmp(argv[1], argv[2]);
-
+\&
printf("%s %s %s\en", argv[1],
(res < 0) ? "<" : (res == 0) ? "==" : ">", argv[2]);
-
+\&
exit(EXIT_SUCCESS);
}
.EE