diff options
author | Drew DeVault <sir@cmpwn.com> | 2017-10-22 22:39:48 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-10-22 22:39:48 -0400 |
commit | b2a9d74a94cd46218b875aac55fe3c83edfb71a5 (patch) | |
tree | 9d0e308c1d7f55736c513e12fb093f0ecd02d5c6 | |
parent | f0add2f8a902f121719ee2eb16bfbab5d135f9bc (diff) | |
parent | a299b9d8757755b3daf7137825ca0bc01a2d9330 (diff) |
Merge pull request #322 from Timidger/drm-failing-fix
Fixes #321, not using result of wl_container_of
-rw-r--r-- | examples/shared.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/shared.c b/examples/shared.c index 4cde15d1..1a1f4be4 100644 --- a/examples/shared.c +++ b/examples/shared.c @@ -414,8 +414,8 @@ static void output_add_notify(struct wl_listener *listener, void *data) { wlr_log(L_DEBUG, "%s %s %"PRId32"mm x %"PRId32"mm", output->make, output->model, output->phys_width, output->phys_height); if (wl_list_length(&output->modes) > 0) { - struct wlr_output_mode *mode = NULL; - wl_container_of((&output->modes)->prev, mode, link); + struct wlr_output_mode *mode; + mode = wl_container_of((&output->modes)->prev, mode, link); wlr_output_set_mode(output, mode); } struct output_state *ostate = calloc(1, sizeof(struct output_state)); |