diff options
author | Chris Bainbridge <chris.bainbridge@gmail.com> | 2023-07-12 21:15:35 +0100 |
---|---|---|
committer | Chris Bainbridge <chris.bainbridge@gmail.com> | 2023-07-12 21:16:32 +0100 |
commit | ae22d12d420efbd8847f9b64b37e7a4cadde2600 (patch) | |
tree | a0b995039b556e131f6d2cbf34f43c858cb2f00a | |
parent | 2897e1769c5d14a74bccbacb483667933807ead8 (diff) |
Free output_ids
-rw-r--r-- | src/drmmode_display.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/drmmode_display.c b/src/drmmode_display.c index 32e7f21..00247ac 100644 --- a/src/drmmode_display.c +++ b/src/drmmode_display.c @@ -1264,8 +1264,10 @@ drmmode_set_mode(xf86CrtcPtr crtc, struct drmmode_fb *fb, DisplayModePtr mode, if (output->crtc != crtc) continue; - if (!drmmode_output->mode_output) - return FALSE; + if (!drmmode_output->mode_output) { + ret = FALSE; + goto out; + } output_ids[output_count] = drmmode_output->mode_output->connector_id; output_count++; @@ -1285,6 +1287,7 @@ drmmode_set_mode(xf86CrtcPtr crtc, struct drmmode_fb *fb, DisplayModePtr mode, "failed to set mode: %s\n", strerror(errno)); } +out: free(output_ids); return ret; } |