diff options
Diffstat (limited to 'usr/src/lib/libc/port/gen')
-rw-r--r-- | usr/src/lib/libc/port/gen/_ftoll.c | 6 | ||||
-rw-r--r-- | usr/src/lib/libc/port/gen/attrat.c | 2 | ||||
-rw-r--r-- | usr/src/lib/libc/port/gen/crypt.c | 22 | ||||
-rw-r--r-- | usr/src/lib/libc/port/gen/memset_s.c | 2 |
4 files changed, 15 insertions, 17 deletions
diff --git a/usr/src/lib/libc/port/gen/_ftoll.c b/usr/src/lib/libc/port/gen/_ftoll.c index 857a52b8a1..66d71f566c 100644 --- a/usr/src/lib/libc/port/gen/_ftoll.c +++ b/usr/src/lib/libc/port/gen/_ftoll.c @@ -24,8 +24,6 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - #include "lint.h" #include <sys/isa_defs.h> #include <floatingpoint.h> @@ -104,7 +102,7 @@ __dtoll(double dval) default: if (exp > 30) { m1 = (m0 << (exp - 30)) | - (m1 >> (62 - exp)) & ~(-1 << (exp - 30)); + (m1 >> (62 - exp)) & ~(UINT_MAX << (exp - 30)); m0 >>= 62 - exp; } else { m1 = m0 >> (30 - exp); @@ -275,7 +273,7 @@ _Q_qtoll(long double longdbl) default: if (exp > 30) { m1 = (m0 << (exp - 30)) | - (m1 >> (62 - exp)) & ~(-1 << (exp - 30)); + (m1 >> (62 - exp)) & ~(UINT_MAX << (exp - 30)); m0 >>= 62 - exp; } else { m1 = m0 >> (30 - exp); diff --git a/usr/src/lib/libc/port/gen/attrat.c b/usr/src/lib/libc/port/gen/attrat.c index 89163a3909..d7c7949175 100644 --- a/usr/src/lib/libc/port/gen/attrat.c +++ b/usr/src/lib/libc/port/gen/attrat.c @@ -310,7 +310,7 @@ setattrat(int basefd, xattr_view_t view, const char *name, nvlist_t *request) void libc_nvlist_free(nvlist_t *nvp) { - nvfree(nvp); + (void) nvfree(nvp); } int diff --git a/usr/src/lib/libc/port/gen/crypt.c b/usr/src/lib/libc/port/gen/crypt.c index 5edc9a1deb..812062644f 100644 --- a/usr/src/lib/libc/port/gen/crypt.c +++ b/usr/src/lib/libc/port/gen/crypt.c @@ -208,10 +208,10 @@ cleanup: * either still allowed or not deprecated. * * RETURN VALUES - * Return a pointer to the new salt, the caller is responsible - * for using free(3c) on the return value. - * Returns NULL on error and sets errno to one of: - * EINVAL, ELIBACC, ENOMEM + * Return a pointer to the new salt, the caller is responsible + * for using free(3c) on the return value. + * Returns NULL on error and sets errno to one of: + * EINVAL, ELIBACC, ENOMEM */ char * crypt_gensalt(const char *oldsalt, const struct passwd *userinfo) @@ -570,7 +570,7 @@ getalgbyname(const char *algname, boolean_t *found) *found = B_TRUE; } } - if (!found) { + if (!(*found)) { errno = EINVAL; goto cleanup; } @@ -731,7 +731,7 @@ free_crypt_policy(struct crypt_policy_s *policy) /* * isa_path - prepend the default dir or patch up the $ISA in path - * Caller is responsible for calling free(3c) on the result. + * Caller is responsible for calling free(3c) on the result. */ static char * isa_path(const char *path) @@ -778,10 +778,10 @@ isa_path(const char *path) /*ARGSUSED*/ static char * _unix_crypt_gensalt(char *gsbuffer, - size_t gsbufflen, - const char *oldpuresalt, - const struct passwd *userinfo, - const char *argv[]) + size_t gsbufflen, + const char *oldpuresalt, + const struct passwd *userinfo, + const char *argv[]) { static const char saltchars[] = "./0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"; @@ -807,7 +807,7 @@ _unix_crypt_gensalt(char *gsbuffer, /* Copyright (c) 1988 AT&T */ -/* All Rights Reserved */ +/* All Rights Reserved */ diff --git a/usr/src/lib/libc/port/gen/memset_s.c b/usr/src/lib/libc/port/gen/memset_s.c index c77b02de20..f1f0d732e9 100644 --- a/usr/src/lib/libc/port/gen/memset_s.c +++ b/usr/src/lib/libc/port/gen/memset_s.c @@ -63,7 +63,7 @@ memset_s(void *s, rsize_t smax, int c, rsize_t n) * memset() called through a volatile pointer to guarantee * it will not be optimized away. */ - (*__memset_vp)(s, v, lim); + (void) (*__memset_vp)(s, v, lim); if (n > RSIZE_MAX) { __throw_constraint_handler_s("memset_s: n > RSIZE_MAX", |