diff options
author | tb <> | 2021-11-25 16:53:58 +0000 |
---|---|---|
committer | tb <> | 2021-11-25 16:53:58 +0000 |
commit | e792591e2f09291fab59cd017f7bc16565fc3853 (patch) | |
tree | a8e8b0d7e1408f56ed6d6631df83fca2e5882d06 /src | |
parent | a6285cd8d6a2d0e66bdc22c3c8e1caa349a2ebd5 (diff) | |
download | openbsd-e792591e2f09291fab59cd017f7bc16565fc3853.tar.gz openbsd-e792591e2f09291fab59cd017f7bc16565fc3853.tar.bz2 openbsd-e792591e2f09291fab59cd017f7bc16565fc3853.zip |
We know how to print a size_t now. Drop a comment and a cast.
ok bluhm inoguchi
Diffstat (limited to 'src')
-rw-r--r-- | src/usr.bin/openssl/passwd.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/usr.bin/openssl/passwd.c b/src/usr.bin/openssl/passwd.c index 4033b55372..a8c7f08dd7 100644 --- a/src/usr.bin/openssl/passwd.c +++ b/src/usr.bin/openssl/passwd.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: passwd.c,v 1.10 2019/07/14 03:30:46 guenther Exp $ */ | 1 | /* $OpenBSD: passwd.c,v 1.11 2021/11/25 16:53:58 tb Exp $ */ |
2 | 2 | ||
3 | #if defined OPENSSL_NO_MD5 | 3 | #if defined OPENSSL_NO_MD5 |
4 | #define NO_MD5CRYPT_1 | 4 | #define NO_MD5CRYPT_1 |
@@ -449,11 +449,9 @@ do_passwd(int passed_salt, char **salt_p, char **salt_malloc_p, | |||
449 | /* truncate password if necessary */ | 449 | /* truncate password if necessary */ |
450 | if ((strlen(passwd) > pw_maxlen)) { | 450 | if ((strlen(passwd) > pw_maxlen)) { |
451 | if (!quiet) | 451 | if (!quiet) |
452 | /* | 452 | BIO_printf(bio_err, |
453 | * XXX: really we should know how to print a size_t, | 453 | "Warning: truncating password to %zu characters\n", |
454 | * not cast it | 454 | pw_maxlen); |
455 | */ | ||
456 | BIO_printf(bio_err, "Warning: truncating password to %u characters\n", (unsigned) pw_maxlen); | ||
457 | passwd[pw_maxlen] = 0; | 455 | passwd[pw_maxlen] = 0; |
458 | } | 456 | } |
459 | assert(strlen(passwd) <= pw_maxlen); | 457 | assert(strlen(passwd) <= pw_maxlen); |