|SUCCESS| [v2,1/1] log: add name query functions

dpdklab at iol.unh.edu dpdklab at iol.unh.edu
Thu Nov 19 20:04:00 CET 2026


Test-Label: ai-code-review
Test-Status: SUCCESS
https://dpdk.org/patch/173052

_AI Code Review_

=== Patch Review: series.patch (via Claude) ===
Review date: 2026-11-19

Info

1. The new tests in app/test/test_logs.c pass the API return value straight to `strcmp()`:

       TEST_ASSERT(strcmp(rte_log_get_level_name(RTE_LOG_ERR), "error") == 0,
       TEST_ASSERT(strcmp(rte_log_get_type_name(logtype1), "logtype1") == 0,

   Both functions can return NULL. If one regresses and returns NULL, the test crashes with a segfault instead of reporting a clean failure. Check for NULL before comparing, for example:

       const char *name = rte_log_get_level_name(RTE_LOG_ERR);
       TEST_ASSERT_NOT_NULL(name, "no name for error log level\n");
       TEST_ASSERT(strcmp(name, "error") == 0, "invalid name for error log level\n");

Review-Result: CLEAN


More information about the test-report mailing list