From 4155e6fb1e8d85dbc777fa85fb61b745647d6505 Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Tue, 28 Jul 2015 19:40:22 +0100 Subject: Client may pass NULL pointer for its pw. --- src/layout.c | 1 - test/basic-layout-tests.c | 4 +--- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/src/layout.c b/src/layout.c index 915475b..b5d74c2 100644 --- a/src/layout.c +++ b/src/layout.c @@ -29,7 +29,6 @@ nslayout_error nslayout_layout_create( assert(css_ctx != NULL); assert(media != NULL); assert(cb != NULL); - assert(pw != NULL); l = calloc(1, sizeof(nslayout_layout)); if (l == NULL) { diff --git a/test/basic-layout-tests.c b/test/basic-layout-tests.c index cdaf5e2..273cdf9 100644 --- a/test/basic-layout-tests.c +++ b/test/basic-layout-tests.c @@ -14,8 +14,6 @@ #define UNUSED(x) (void)(x) #endif -int pw; - static nslayout_error nslayout_test_callback( nslayout_layout *layout, void *pw, @@ -50,7 +48,7 @@ START_TEST (test_nslayout_layout_create_ok) css_ctx, &media, nslayout_test_callback, - &pw, + NULL, &layout); fail_unless(error == NSLAYOUT_OK, "Unable to create layout"); -- cgit v1.2.3