summaryrefslogtreecommitdiff
path: root/usr/src/lib/libadm/common/ckstr.c
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@nexenta.com>2010-11-15 20:03:27 -0800
committerGarrett D'Amore <garrett@nexenta.com>2010-11-15 20:03:27 -0800
commit4656d4747c8743290bfbe910c64cd75eb4e4af8d (patch)
tree241d8b3f0b8796e33937c6a27c670eba002f8f04 /usr/src/lib/libadm/common/ckstr.c
parent60bec29ea42d65ac648c69b0fb189273e286ca57 (diff)
downloadillumos-joyent-4656d4747c8743290bfbe910c64cd75eb4e4af8d.tar.gz
420 remove patch (sparse package) support from svr4 pkg
421 libpkg and libadm need to be lint clean Reviewed by: gwr@nexenta.com Reviewed by: peter.tribble@gmail.com Approved by: gwr@nexenta.com
Diffstat (limited to 'usr/src/lib/libadm/common/ckstr.c')
-rw-r--r--usr/src/lib/libadm/common/ckstr.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/usr/src/lib/libadm/common/ckstr.c b/usr/src/lib/libadm/common/ckstr.c
index e01717f233..b72d6900b0 100644
--- a/usr/src/lib/libadm/common/ckstr.c
+++ b/usr/src/lib/libadm/common/ckstr.c
@@ -28,8 +28,6 @@
* Use is subject to license terms.
*/
-#pragma ident "%Z%%M% %I% %E% SMI"
-
#include <stdio.h>
#include <string.h>
#include <limits.h>
@@ -50,14 +48,14 @@ extern int __step(const char *, const char *);
#define ERRMSG2 \
"Pattern matching has failed."
#define ERRMSG3 \
- "Please enter a string which contains no imbedded, \
+ "Please enter a string which contains no embedded, \
leading or trailing spaces or tabs."
#define HLPMSG0 "Please enter a string"
#define HLPMSG1 "Please enter a string containing no more than %d characters"
#define HLPMSG2 "matches one of the following patterns:"
#define HLPMSG3 "matches the following pattern:"
-#define HLPMSG4 "contains no imbedded, leading or trailing spaces or tabs."
+#define HLPMSG4 "contains no embedded, leading or trailing spaces or tabs."
static char *errstr;
@@ -119,7 +117,8 @@ ckstr_err(char *regexp[], int length, char *error, char *input)
if (input) {
if (ckstr_val(regexp, length, input)) {
- (void) sprintf(temp, errstr, length);
+ /* LINTED E_SEC_PRINTF_VAR_FMT */
+ (void) snprintf(temp, sizeof (temp), errstr, length);
puterror(stdout, temp, error);
return;
}
@@ -178,7 +177,8 @@ start:
return (3);
}
if (ckstr_val(regexp, length, input)) {
- (void) sprintf(errbuf, errstr, length);
+ /* LINTED E_SEC_PRINTF_VAR_FMT */
+ (void) snprintf(errbuf, sizeof (errbuf), errstr, length);
puterror(stderr, errbuf, error);
goto start;
}