summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormike <mike@FreeBSD.org>2002-09-20 08:24:01 +0000
committermike <mike@FreeBSD.org>2002-09-20 08:24:01 +0000
commita33d7be6d91b82aecdb4f7f084eb48e928ba376e (patch)
tree3c58349c0de53d82be66cb7249f05c93075bd9ed
parent8286a42d542808c026b1d91d10c9db2771ed82d9 (diff)
downloadFreeBSD-src-a33d7be6d91b82aecdb4f7f084eb48e928ba376e.zip
FreeBSD-src-a33d7be6d91b82aecdb4f7f084eb48e928ba376e.tar.gz
Add restrict type-qualifier.
-rw-r--r--lib/libc/stdlib/strfmon.32
-rw-r--r--lib/libc/stdlib/strfmon.c3
2 files changed, 3 insertions, 2 deletions
diff --git a/lib/libc/stdlib/strfmon.3 b/lib/libc/stdlib/strfmon.3
index 2427e35..2ede7cf 100644
--- a/lib/libc/stdlib/strfmon.3
+++ b/lib/libc/stdlib/strfmon.3
@@ -35,7 +35,7 @@
.Sh SYNOPSIS
.In monetary.h
.Ft ssize_t
-.Fn strfmon "char *s" "size_t maxsize" "const char *format" "..."
+.Fn strfmon "char * restrict s" "size_t maxsize" "const char * restrict format" "..."
.Sh DESCRIPTION
The
.Fn strfmon
diff --git a/lib/libc/stdlib/strfmon.c b/lib/libc/stdlib/strfmon.c
index aa9b318..d30f268 100644
--- a/lib/libc/stdlib/strfmon.c
+++ b/lib/libc/stdlib/strfmon.c
@@ -88,7 +88,8 @@ static int __calc_left_pad(int, char *);
static char *__format_grouped_double(double, int *, int, int, int);
ssize_t
-strfmon(char *s, size_t maxsize, const char *format, ...)
+strfmon(char * __restrict s, size_t maxsize, const char * __restrict format,
+ ...)
{
va_list ap;
char *dst; /* output destination pointer */
OpenPOWER on IntegriCloud