]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
test_objagg: Test the correct variable
authorDan Carpenter <dan.carpenter@oracle.com>
Wed, 13 Feb 2019 08:58:20 +0000 (11:58 +0300)
committerDavid S. Miller <davem@davemloft.net>
Thu, 14 Feb 2019 06:13:29 +0000 (22:13 -0800)
There is a typo here.  We intended to check "objagg2" but we instead
test "objagg" which is not an error pointer.

Fixes: 9069a3817d82 ("lib: objagg: implement optimization hints assembly and use hints for object creation")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
lib/test_objagg.c

index 3744573b636554bf5ed0c3983ed14a00c8047956..3dd45777b13c922fc687fb8c787a37c4a2461d42 100644 (file)
@@ -952,8 +952,8 @@ static int test_hints_case(const struct hints_case *hints_case)
        }
 
        objagg2 = objagg_create(&delta_ops, hints, &world2);
-       if (IS_ERR(objagg))
-               return PTR_ERR(objagg);
+       if (IS_ERR(objagg2))
+               return PTR_ERR(objagg2);
 
        for (i = 0; i < hints_case->key_ids_count; i++) {
                objagg_obj = world_obj_get(&world2, objagg2,