summaryrefslogtreecommitdiff
path: root/src/lib/ecore_drm2/ecore_drm2_device.c
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@osg.samsung.com>2016-05-23 12:53:49 -0400
committerChris Michael <cpmichael@osg.samsung.com>2016-05-27 11:57:53 -0400
commitc1253164b2bc944b37b5d04b7b5814f6bbcde8bb (patch)
treec35da892e92187fb315d929a78e037f15165dfd3 /src/lib/ecore_drm2/ecore_drm2_device.c
parent7b5af2f0df36e896878c3609ec870ecd73c953f5 (diff)
ecore-drm2: perform logind connection after finding device path in ecore_drm2_device_find
Diffstat (limited to 'src/lib/ecore_drm2/ecore_drm2_device.c')
-rw-r--r--src/lib/ecore_drm2/ecore_drm2_device.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/lib/ecore_drm2/ecore_drm2_device.c b/src/lib/ecore_drm2/ecore_drm2_device.c
index 1e9ded816e..ca43bcff95 100644
--- a/src/lib/ecore_drm2/ecore_drm2_device.c
+++ b/src/lib/ecore_drm2/ecore_drm2_device.c
@@ -104,13 +104,6 @@ ecore_drm2_device_find(const char *seat, unsigned int tty, Eina_Bool sync)
104 dev = calloc(1, sizeof(Ecore_Drm2_Device)); 104 dev = calloc(1, sizeof(Ecore_Drm2_Device));
105 if (!dev) return NULL; 105 if (!dev) return NULL;
106 106
107 dev->em = elput_manager_connect(seat, tty, sync);
108 if (!dev->em)
109 {
110 ERR("Could not connect to input manager");
111 goto man_err;
112 }
113
114 dev->path = _drm2_device_find(seat); 107 dev->path = _drm2_device_find(seat);
115 if (!dev->path) 108 if (!dev->path)
116 { 109 {
@@ -118,11 +111,18 @@ ecore_drm2_device_find(const char *seat, unsigned int tty, Eina_Bool sync)
118 goto path_err; 111 goto path_err;
119 } 112 }
120 113
114 dev->em = elput_manager_connect(seat, tty, sync);
115 if (!dev->em)
116 {
117 ERR("Could not connect to input manager");
118 goto man_err;
119 }
120
121 return dev; 121 return dev;
122 122
123path_err:
124 elput_manager_disconnect(dev->em);
125man_err: 123man_err:
124 eina_stringshare_del(dev->path);
125path_err:
126 free(dev); 126 free(dev);
127 return NULL; 127 return NULL;
128} 128}