From cee60fc36fe915c3aee52f68caa87b0b8e56cc50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Wed, 8 Nov 2023 13:50:39 +0100 Subject: [PATCH] tree-wide: use the usual spelling of "cannot" (There's a bunch more in src/basic/linux/, but those files are copied from the kernel and should not be modified.) --- meson.build | 2 +- .../cryptsetup-tokens/cryptsetup-token-systemd-fido2.c | 6 +++--- .../cryptsetup-tokens/cryptsetup-token-systemd-pkcs11.c | 2 +- .../cryptsetup-tokens/cryptsetup-token-systemd-tpm2.c | 8 ++++---- src/cryptsetup/cryptsetup-tokens/luks2-pkcs11.c | 2 +- src/locale/localed.c | 2 +- src/resolve/resolved-dnstls-openssl.c | 2 +- 7 files changed, 12 insertions(+), 12 deletions(-) diff --git a/meson.build b/meson.build index 32a181e50d..bc61ca4801 100644 --- a/meson.build +++ b/meson.build @@ -1230,7 +1230,7 @@ libcryptsetup = get_option('libcryptsetup') libcryptsetup_plugins = get_option('libcryptsetup-plugins') if libcryptsetup_plugins.enabled() if libcryptsetup.disabled() - error('libcryptsetup-plugins can not be requested without libcryptsetup') + error('libcryptsetup-plugins cannot be requested without libcryptsetup') endif libcryptsetup = libcryptsetup_plugins endif diff --git a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-fido2.c b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-fido2.c index 3027804065..fdb3b17d2d 100644 --- a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-fido2.c +++ b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-fido2.c @@ -45,7 +45,7 @@ _public_ int cryptsetup_token_open_pin( r = crypt_normalize_pin(pin, pin_size, &pin_string); if (r < 0) - return crypt_log_debug_errno(cd, r, "Can not normalize PIN: %m"); + return crypt_log_debug_errno(cd, r, "Cannot normalize PIN: %m"); return acquire_luks2_key(cd, json, (const char *)usrptr, pin_string, password, password_len); } @@ -104,11 +104,11 @@ _public_ void cryptsetup_token_dump( r = crypt_dump_buffer_to_hex_string(cid, cid_size, &cid_str); if (r < 0) - return (void) crypt_log_debug_errno(cd, r, "Can not dump " TOKEN_NAME " content: %m"); + return (void) crypt_log_debug_errno(cd, r, "Cannot dump " TOKEN_NAME " content: %m"); r = crypt_dump_buffer_to_hex_string(salt, salt_size, &salt_str); if (r < 0) - return (void) crypt_log_debug_errno(cd, r, "Can not dump " TOKEN_NAME " content: %m"); + return (void) crypt_log_debug_errno(cd, r, "Cannot dump " TOKEN_NAME " content: %m"); if (required & FIDO2ENROLL_PIN) client_pin_req_str = "true"; diff --git a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-pkcs11.c b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-pkcs11.c index c3e7fbd061..2ac8a270c5 100644 --- a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-pkcs11.c +++ b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-pkcs11.c @@ -95,7 +95,7 @@ _public_ void cryptsetup_token_dump( r = crypt_dump_buffer_to_hex_string(pkcs11_key, pkcs11_key_size, &key_str); if (r < 0) - return (void) crypt_log_debug_errno(cd, r, "Can not dump " TOKEN_NAME " content: %m"); + return (void) crypt_log_debug_errno(cd, r, "Cannot dump " TOKEN_NAME " content: %m"); crypt_log(cd, "\tpkcs11-uri: %s\n", pkcs11_uri); crypt_log(cd, "\tpkcs11-key: %s\n", key_str); diff --git a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-tpm2.c b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-tpm2.c index 6da80896cd..6fee8319a7 100644 --- a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-tpm2.c +++ b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-systemd-tpm2.c @@ -68,7 +68,7 @@ _public_ int cryptsetup_token_open_pin( r = crypt_normalize_pin(pin, pin_size, &pin_string); if (r < 0) - return crypt_log_debug_errno(cd, r, "Can not normalize PIN: %m"); + return crypt_log_debug_errno(cd, r, "Cannot normalize PIN: %m"); if (usrptr) params = *(systemd_tpm2_plugin_params *)usrptr; @@ -222,15 +222,15 @@ _public_ void cryptsetup_token_dump( r = crypt_dump_buffer_to_hex_string(blob, blob_size, &blob_str); if (r < 0) - return (void) crypt_log_debug_errno(cd, r, "Can not dump " TOKEN_NAME " content: %m"); + return (void) crypt_log_debug_errno(cd, r, "Cannot dump " TOKEN_NAME " content: %m"); r = crypt_dump_buffer_to_hex_string(pubkey, pubkey_size, &pubkey_str); if (r < 0) - return (void) crypt_log_debug_errno(cd, r, "Can not dump " TOKEN_NAME " content: %m"); + return (void) crypt_log_debug_errno(cd, r, "Cannot dump " TOKEN_NAME " content: %m"); r = crypt_dump_buffer_to_hex_string(policy_hash, policy_hash_size, &policy_hash_str); if (r < 0) - return (void) crypt_log_debug_errno(cd, r, "Can not dump " TOKEN_NAME " content: %m"); + return (void) crypt_log_debug_errno(cd, r, "Cannot dump " TOKEN_NAME " content: %m"); crypt_log(cd, "\ttpm2-hash-pcrs: %s\n", strna(hash_pcrs_str)); crypt_log(cd, "\ttpm2-pcr-bank: %s\n", strna(tpm2_hash_alg_to_string(pcr_bank))); diff --git a/src/cryptsetup/cryptsetup-tokens/luks2-pkcs11.c b/src/cryptsetup/cryptsetup-tokens/luks2-pkcs11.c index 8cbb1f7d88..178fc7a87b 100644 --- a/src/cryptsetup/cryptsetup-tokens/luks2-pkcs11.c +++ b/src/cryptsetup/cryptsetup-tokens/luks2-pkcs11.c @@ -217,7 +217,7 @@ int acquire_luks2_key( base64_encoded_size = base64mem(decrypted_key, decrypted_key_size, &base64_encoded); if (base64_encoded_size < 0) - return crypt_log_error_errno(cd, (int) base64_encoded_size, "Can not base64 encode key: %m"); + return crypt_log_error_errno(cd, (int) base64_encoded_size, "Cannot base64 encode key: %m"); *ret_password = TAKE_PTR(base64_encoded); *ret_password_size = base64_encoded_size; diff --git a/src/locale/localed.c b/src/locale/localed.c index f544a73580..5d96237fae 100644 --- a/src/locale/localed.c +++ b/src/locale/localed.c @@ -192,7 +192,7 @@ static int locale_gen_process_locale(char *new_locale[static _VARIABLE_LC_MAX], log_error_errno(r, "Failed to enable invalid locale %s for generation.", new_locale[p]); return sd_bus_error_setf(error, SD_BUS_ERROR_INVALID_ARGS, - "Can not enable locale generation for invalid locale: %s", + "Cannot enable locale generation for invalid locale: %s", new_locale[p]); } if (r < 0) { diff --git a/src/resolve/resolved-dnstls-openssl.c b/src/resolve/resolved-dnstls-openssl.c index b217417a1a..fbcee7fc63 100644 --- a/src/resolve/resolved-dnstls-openssl.c +++ b/src/resolve/resolved-dnstls-openssl.c @@ -327,7 +327,7 @@ ssize_t dnstls_stream_writev(DnsStream *stream, const struct iovec *iov, size_t if (iovcnt == 1) return dnstls_stream_write(stream, iov[0].iov_base, iov[0].iov_len); - /* As of now, OpenSSL can not accumulate multiple writes, so join into a + /* As of now, OpenSSL cannot accumulate multiple writes, so join into a single buffer. Suboptimal, but better than multiple SSL_write calls. */ count = iovec_total_size(iov, iovcnt); buf = new(char, count);