test_objagg: Fix warning.
authorDavid S. Miller <davem@davemloft.net>
Thu, 15 Nov 2018 22:57:09 +0000 (14:57 -0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 15 Nov 2018 22:57:09 +0000 (14:57 -0800)
lib/test_objagg.c: In function ‘test_delta_action_item’:
./include/linux/printk.h:308:2: warning: ‘errmsg’ may be used uninitialized in this function [-Wmaybe-uninitialized]

Signed-off-by: David S. Miller <davem@davemloft.net>
lib/test_objagg.c

index aac5d8e8800c4bdb06624b36b5e3761fb773ba25..ab57144bb0cd68c2fefa70d0957356a840f185eb 100644 (file)
@@ -769,6 +769,7 @@ static int test_delta_action_item(struct world *world,
        if (err)
                goto errout;
 
+       errmsg = NULL;
        err = check_expect_stats(objagg, &action_item->expect_stats, &errmsg);
        if (err) {
                pr_err("Key %u: Stats: %s\n", action_item->key_id, errmsg);