tree-wide: Use assert_se() instead of assert() in various places

assert() is compiled away if NDEBUG is set which causes an unused
variable warning in various places when the next commit is applied
so let's use assert_se() to avoid these warnings.
This commit is contained in:
Daan De Meyer
2025-04-23 13:48:16 +02:00
parent a843382d1e
commit 5332be60d3
5 changed files with 15 additions and 15 deletions
+1 -1
View File
@@ -4897,7 +4897,7 @@ static int tpm2_kdfe(
void *end = mempcpy(mempcpy(stpcpy(info, label) + 1, context_u, context_u_size), context_v, context_v_size);
/* assert we copied exactly the right amount that we allocated */
assert(end > info && (uintptr_t) end - (uintptr_t) info == info_len);
assert_se(end > info && (uintptr_t) end - (uintptr_t) info == info_len);
_cleanup_free_ void *buf = NULL;
r = kdf_ss_derive(