mirror of
https://github.com/systemd/systemd.git
synced 2026-11-06 13:27:45 +00:00
test-resolve-tables: convert to new ASSERT macros
Replace assert_se() with the typed ASSERT_* macros throughout, so that a failing assertion logs the values involved.
This commit is contained in:
1 parent
ae08b06261
commit
a30d102de3
1 file changed
+2
-2
@@ -23,7 +23,7 @@ int main(int argc, char **argv) {
|
||||
const char *s;
|
||||
|
||||
s = dns_type_to_string(i);
|
||||
assert_se(s == NULL || strlen(s) < _DNS_TYPE_STRING_MAX);
|
||||
ASSERT_LT(strlen_ptr(s), _DNS_TYPE_STRING_MAX);
|
||||
|
||||
if (s)
|
||||
log_info("%-*s %s%s%s%s%s%s%s%s%s",
|
||||
@@ -44,7 +44,7 @@ int main(int argc, char **argv) {
|
||||
const char *s;
|
||||
|
||||
s = dns_class_to_string(i);
|
||||
assert_se(s == NULL || strlen(s) < _DNS_CLASS_STRING_MAX);
|
||||
ASSERT_LT(strlen_ptr(s), _DNS_CLASS_STRING_MAX);
|
||||
|
||||
if (s)
|
||||
log_info("%-*s %s%s",
|
||||
|
||||
Reference in new issue
Block a user