From: Karel Zak Date: Mon, 26 May 2025 16:55:36 +0000 (+0200) Subject: libmount: (verity) use messages API for important errors X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=eb3003a7dbee376c264ccf0b58e3c25617fd8707;p=thirdparty%2Futil-linux.git libmount: (verity) use messages API for important errors Signed-off-by: Karel Zak --- diff --git a/libmount/src/hook_veritydev.c b/libmount/src/hook_veritydev.c index 75d5ebe79..801eeaddd 100644 --- a/libmount/src/hook_veritydev.c +++ b/libmount/src/hook_veritydev.c @@ -543,7 +543,8 @@ static int setup_veritydev( struct libmnt_context *cxt, if (!rc) { DBG(HOOK, ul_debugobj(hs, "comparing root hash of existing device with %s", root_hash)); if (memcmp(key, root_hash_binary, hash_size)) { - DBG(HOOK, ul_debugobj(hs, "existing device's hash does not match with %s", root_hash)); + /* TRANSLATORS: Don't translate "e ". It's a message classifier. */ + mnt_context_append_mesg(cxt, _("e device's hash does not match with root hash")); rc = -EINVAL; goto done; } @@ -561,8 +562,9 @@ static int setup_veritydev( struct libmnt_context *cxt, */ #ifdef HAVE_CRYPT_ACTIVATE_BY_SIGNED_KEY if (!!hash_sig != !!(crypt_params.flags & CRYPT_VERITY_ROOT_HASH_SIGNATURE)) { + /* TRANSLATORS: Don't translate "e ". It's a message classifier. */ + mnt_context_append_mesg(cxt, _("e device and mount have to either be both opened with signature or both without")); rc = -EINVAL; - DBG(HOOK, ul_debugobj(hs, "existing device and new mount have to either be both opened with signature or both without")); goto done; } #endif