summaryrefslogtreecommitdiff
path: root/usr/src/common/util
diff options
context:
space:
mode:
authorMatthew Ahrens <mahrens@delphix.com>2016-11-05 20:59:10 -0700
committerMatthew Ahrens <mahrens@delphix.com>2016-11-06 22:28:19 -0800
commit3c5da275f68706f8301ea6c616a098430d84a71a (patch)
tree04214bb89d0f06fcf24e9123677e94321931f140 /usr/src/common/util
parent55a13001fbd9772352bc050632ef966a249dc73b (diff)
downloadillumos-joyent-3c5da275f68706f8301ea6c616a098430d84a71a.tar.gz
7498 snprintf is incorrectly annotated with PRINTFLIKE1
Reviewed by: Sebastien Roy <sebastien.roy@delphix.com> Reviewed by: George Wilson <george.wilson@delphix.com> Reviewed by: Robert Mustacchi <rm@joyent.com> Approved by: Gordon Ross <gordon.w.ross@gmail.com>
Diffstat (limited to 'usr/src/common/util')
-rw-r--r--usr/src/common/util/string.c6
-rw-r--r--usr/src/common/util/string.h6
2 files changed, 10 insertions, 2 deletions
diff --git a/usr/src/common/util/string.c b/usr/src/common/util/string.c
index 1388f5772e..26e5744485 100644
--- a/usr/src/common/util/string.c
+++ b/usr/src/common/util/string.c
@@ -25,6 +25,10 @@
*/
/*
+ * Copyright (c) 2016 by Delphix. All rights reserved.
+ */
+
+/*
* Implementations of the functions described in vsnprintf(3C) and string(3C),
* for use by the kernel, the standalone, and kmdb. Unless otherwise specified,
* these functions match the section 3C manpages.
@@ -313,7 +317,7 @@ next_fmt:
return (bufp - buf);
}
-/*PRINTFLIKE1*/
+/*PRINTFLIKE3*/
size_t
snprintf(char *buf, size_t buflen, const char *fmt, ...)
{
diff --git a/usr/src/common/util/string.h b/usr/src/common/util/string.h
index 6a109bf930..2067412294 100644
--- a/usr/src/common/util/string.h
+++ b/usr/src/common/util/string.h
@@ -24,6 +24,10 @@
* Use is subject to license terms.
*/
+/*
+ * Copyright (c) 2016 by Delphix. All rights reserved.
+ */
+
#ifndef _COMMON_UTIL_STRING_H
#define _COMMON_UTIL_STRING_H
@@ -36,7 +40,7 @@ extern "C" {
#if !defined(_KMDB) && (!defined(_BOOT) || defined(__sparc))
extern size_t vsnprintf(char *, size_t, const char *, va_list);
-/*PRINTFLIKE1*/
+/*PRINTFLIKE3*/
extern size_t snprintf(char *, size_t, const char *, ...);
#if defined(_BOOT) && defined(__sparc)