diff options
author | Drew DeVault <sir@cmpwn.com> | 2018-04-04 18:52:44 -0400 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2018-04-04 18:52:44 -0400 |
commit | 5d444b34f6af17894e2808c9d25948db625dabde (patch) | |
tree | 4702abb406a59fb8588cbd2019741e99d40bcbfe /swaylock/main.c | |
parent | 053b51c3ff63147aed25400efb42c00ee3de90b9 (diff) |
Address review feedback from @emersion
Diffstat (limited to 'swaylock/main.c')
-rw-r--r-- | swaylock/main.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/swaylock/main.c b/swaylock/main.c index 1eda3afc..1d522184 100644 --- a/swaylock/main.c +++ b/swaylock/main.c @@ -216,7 +216,8 @@ int main(int argc, char **argv) { wl_list_init(&state.surfaces); state.xkb.context = xkb_context_new(XKB_CONTEXT_NO_FLAGS); - assert(state.display = wl_display_connect(NULL)); + state.display = wl_display_connect(NULL); + assert(state.display); struct wl_registry *registry = wl_display_get_registry(state.display); wl_registry_add_listener(registry, ®istry_listener, &state); @@ -236,8 +237,8 @@ int main(int argc, char **argv) { wl_list_for_each(surface, &state.surfaces, link) { surface->image = background_image; - assert(surface->surface = - wl_compositor_create_surface(state.compositor)); + surface->surface = wl_compositor_create_surface(state.compositor); + assert(surface->surface); surface->layer_surface = zwlr_layer_shell_v1_get_layer_surface( state.layer_shell, surface->surface, surface->output, |