mirror of
https://github.com/libratbag/libratbag.git
synced 2026-11-07 23:23:52 +01:00
Always return NULL from the _unref() calls
There's no good reason to return the object from the unref() call other than for testing purposes, and we can work around this by using valgrind instead. The API is a lot more consistent when we always return NULL. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
@@ -107,9 +107,9 @@ START_TEST(context_ref)
|
||||
ck_assert_ptr_eq(lr, lr2);
|
||||
|
||||
lr2 = ratbag_unref(lr2);
|
||||
ck_assert_ptr_eq(lr2, lr);
|
||||
ck_assert_ptr_eq(lr2, NULL);
|
||||
|
||||
lr2 = ratbag_unref(lr2);
|
||||
lr2 = ratbag_unref(lr);
|
||||
ck_assert_ptr_eq(lr2, NULL);
|
||||
}
|
||||
END_TEST
|
||||
|
||||
Reference in New Issue
Block a user