summaryrefslogtreecommitdiff
path: root/src/lib/ecore_drm2/ecore_drm2_device.c
diff options
context:
space:
mode:
authorChris Michael <cp.michael@samsung.com>2017-03-28 09:18:37 -0400
committerChris Michael <cp.michael@samsung.com>2017-04-18 07:55:10 -0400
commitd3d9ab2296df8e77eb8c6998e5f2cf8860956f13 (patch)
tree3bf9fe8025cdb2a9f2531da35b363655f646ca7c /src/lib/ecore_drm2/ecore_drm2_device.c
parent345fefd3ef841381a6a0206297a24df88afd311a (diff)
ecore-drm2: Free any previous atomic request
If we fail the atomic request merge, cleanup any previous request and just use the new one. Signed-off-by: Chris Michael <cp.michael@samsung.com>
Diffstat (limited to 'src/lib/ecore_drm2/ecore_drm2_device.c')
-rw-r--r--src/lib/ecore_drm2/ecore_drm2_device.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/lib/ecore_drm2/ecore_drm2_device.c b/src/lib/ecore_drm2/ecore_drm2_device.c
index cb659ad4a5..74284c4502 100644
--- a/src/lib/ecore_drm2/ecore_drm2_device.c
+++ b/src/lib/ecore_drm2/ecore_drm2_device.c
@@ -961,7 +961,12 @@ ecore_drm2_atomic_commit_test(Ecore_Drm2_Device *device)
961 ret = sym_drmModeAtomicMerge(device->atomic_req, req); 961 ret = sym_drmModeAtomicMerge(device->atomic_req, req);
962 if (ret < 0) 962 if (ret < 0)
963 { 963 {
964 /* we failed to merge for some reason. just use this req */ 964 /* we failed to merge for some reason. */
965
966 /* clear any previous request */
967 sym_drmModeAtomicFree(device->atomic_req);
968
969 /* just use the new request */
965 device->atomic_req = req; 970 device->atomic_req = req;
966 } 971 }
967 } 972 }