Commit Graph

323 Commits

Author SHA1 Message Date
Chris Michael da0b4d4850 ecore-x: add safety checks for _ecore_x_disp in some functions
xlib immediately crashes upon being passed a null DISPLAY object,
so every function in ecore-x should likely have safety checks such as these.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-02-23 08:43:50 -05:00
Chris Michael a0ad57bb16 ecore-x: add safety checks for _ecore_x_disp in some functions
xlib immediately crashes upon being passed a null DISPLAY object,
so every function in ecore-x should likely have safety checks such as these.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-02-22 14:50:35 -05:00
Chris Michael 2be9bfc2a8 ecore-x: Add safety checks for NULL display in dpms functions
xlib immediately crashes upon being passed a NULL display object,
so every function in ecore-x should likely have safety checks such as these.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-02-17 08:16:29 -05:00
Chris Michael 5b2580b62e ecore-x: Add safety checks for NULL _ecore_x_disp in dnd functions
xlib immediately crashes upon being passed a NULL display object,
so every function in ecore-x should likely have safety checks such as
these.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-02-16 15:51:58 -05:00
Chris Michael 3bc6a4bedf ecore-x: Add EINA_SAFETY checks for missing display
xlib immediately crashes upon being passed a null DISPLAY object,
so every function in ecore-x should likely have safety checks such
as these.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-02-12 08:28:10 -05:00
Chris Michael ef13b57948 ecore-x: Add EINA_SAFETY checks for missing display
xlib immediately crashes upon being passed a null DISPLAY object,
so every function in ecore-x should likely have safety checks such
as these.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-02-12 08:28:10 -05:00
Chris Michael eb11b7f26e ecore-x: Add EINA_SAFETY checks for missing display
xlib immediately crashes upon being passed a null DISPLAY object,
so every function in ecore-x should likely have safety checks such
as these.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-02-12 08:28:10 -05:00
Chris Michael 43fa91f428 ecore-x: Fix compiler warnings about return values
This is an "oopsie" fix from my previous commit wrt adding EINA_SAFETY
checks. I made an oopsie and didn't realize that these 2 functions
were expecting int returns.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-02-11 11:21:50 -05:00
Chris Michael adeb28a1c0 ecore-x: Add EINA_SAFETY checks for missing display
xlib immediately crashes upon being passed a null DISPLAY object,
so every function in ecore-x should likely have safety checks such
as these.

@ref 210b3e6c62

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-02-11 10:12:10 -05:00
Mike Blumenkrantz 210b3e6c62 ecore-x: add safety checks for _ecore_x_disp in some functions
xlib immediately crashes upon being passed a null DISPLAY object,
so every function in ecore-x should likely have safety checks such as
these. an easy project for anyone who has some free time

@fix
2016-01-18 17:19:00 -05:00
Ji-Youn Park d0d9747853 ecore_x: fix memory leak
fix memory leak in xcb event handler.
   @fix
2015-12-24 13:11:45 +08:30
Ji-Youn Park 1a3cb45f1c ecore_x: fix memory leak
check return value type of XGetWindowProperty.
   @fix
2015-12-24 09:57:34 +08:30
Carsten Haitzler 7d57dfbe9c efl - ecore-x randr - fix coverity issue found after previous leak fix
fix coverity issue pointed out in the previous commit fix:

dadc1451e7

use after free of ptr (free was in wrong spot)

@fix
2015-12-09 14:21:10 +09:00
Carsten Haitzler dadc1451e7 efl - ecore-x xrandr - fix memleaks of properties fetched
while doing some debugging, ifound we have been leaking these xrandr
properites that were malloced in certain cases. this fixes these leaks.

@fix
2015-12-07 20:07:31 +09:00
Vincent Torri 3b44645363 efl: add binary mode to f(re)open() calls
This allows better compatibility with Windows

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-12-05 21:04:36 +01:00
Jean Guyomarc'h 4ab8471ef0 ecore_x: factorize multiple calls to strlen()
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-12-01 12:15:32 -08:00
indefini fb75f6df5a ecore_x: don't add a x selection clear event if the time is the same as when selection was made.
Summary:
Without this, selection can get cleared when changing focus.
For example, if we have 2 entries:
The first entry is focused and has a selection.
When we focus the second entry, we want to select all the text.
But the old selection gets unfocused and sends a clear signal
to the new focused entry and it gets unselected.

This should fix T2739.

Reviewers: raster, tasn, devilhorns

Subscribers: herdsman, thiepha, cedric

Maniphest Tasks: T2739

Differential Revision: https://phab.enlightenment.org/D3127

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-11-09 15:27:26 -08:00
Carsten Haitzler 60d78b5b97 efl - make drm vsync handle broken drm irq timestamps
i found that intel drm device gives BROKEN timestamps vs system clock
- it is off by about 0.3 to 0.4ms - this means the vsync event is in
the future vs when we actually wake up and do processing - this leads
to bizare timelines and likely odd event and animation handling.

fix this by detecting it and figuring out an average delay and
offsetting events by that in future, but until then, use "now" when
the drm thread wakes up as the timestamp.

@fix
2015-10-28 20:45:07 +09:00
Srivardhan Hebbar 30ad41cf99 ecore_x: remove useless assignment.
Summary: Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Differential Revision: https://phab.enlightenment.org/D3206

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-10-21 14:01:41 -07:00
Srivardhan Hebbar a3ff6aff61 ecore_x: removing useless assignment variable.
Summary:
Assigning to NULL has no effect in the function calling this. So changed it to void.
Some compiler complain about this kind of construct. It is better to use the (void)
construct for silencing unused parameter with different kind of configure option.

Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Differential Revision: https://phab.enlightenment.org/D3180

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-10-20 14:01:15 -07:00
Srivardhan Hebbar e2167fe2a0 ecore_x: removing useless assignment.
Summary:
The assigned value has no effect outside the function. So removing it.

Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Differential Revision: https://phab.enlightenment.org/D3181

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-10-19 11:24:52 -07:00
Srivardhan Hebbar c406cf79e1 ecore_x: handling realloc failure.
Summary:
If realloc fails, lst would be NULL. So handling it.
Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Differential Revision: https://phab.enlightenment.org/D3182

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-10-19 11:23:33 -07:00
Srivardhan Hebbar 412d311830 ecore_x: removing useless assignment pointer.
Summary:
The assignment to size has no effect on the caller and compiler
complain about it. Do shutdown compiler complain in a more reliable
way.

Signed-off-by:
Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3156

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-10-12 14:01:23 -07:00
Mrunal Sovani db017c5b47 ecore_x: Optimize _ecore_x_modifiers_get()
Summary:
_ecore_x_modifiers_get() causes multiple XGetModifierMapping requests to the
server through _ecore_x_key_mask_get() function. _ecore_x_key_mask_get()
requests XModifierKeymap pointer every time it gets executed.
This can be optimized by a single XGetModifierMapping request in the
_ecore_x_modifiers_get() function itself and then passing the XModifierKeymap
pointer thus retrieved to the _ecore_x_key_mask_get() function.

Reviewers: raster, Hermet, tasn, zmike

Subscribers: yashu21985, alok25, sachin.dev, singh.amitesh, cedric

Differential Revision: https://phab.enlightenment.org/D3166
2015-10-12 12:05:49 -04:00
Mrunal Sovani 2fc00da9fa Ecore_xcb_keymap: Fix memory leak in _ecore_xcb_keymap_finilize
Summary:
xcb_get_modifier_mapping_reply_t *reply is obtained from
xcb_get_modifier_mapping_reply and should be freed after use.

Reviewers: raster, Hermet, tasn, zmike

Subscribers: singh.amitesh, yashu21985, alok25, sachin.dev, cedric

Differential Revision: https://phab.enlightenment.org/D3167

@fix
2015-10-09 13:18:18 -04:00
Srivardhan Hebbar 308e1536cf ecor_xcb: removing useless assignment.
Summary:
The assignment of NULL will have no effect on the caller. So removed that statment.

Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Reviewed By: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3153

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-10-09 10:00:32 +02:00
Srivardhan Hebbar 675ca609b5 ecore_xcb: initializing the uninitialized variable.
Summary:
realwin is uninitialized and is being checked against 0 at 384. It is set at 377 only if win2 == win, else it remains uninitialized. So initializing it to NULL.
Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3154

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-10-09 10:00:32 +02:00
Srivardhan Hebbar 84127a8963 ecore_xcb: handle realloc failure.
Summary:
If realloc fails, then lst would be NULL, so assigning lst[i] only if realloc is successful, else assigning lst to previous memory location.

Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Reviewed By: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3155

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-10-09 10:00:32 +02:00
Derek Foreman 7c6c1a081a ecore_x: Remove XPrint usage
Summary:
Xprint has been deprecated since 2008.

It's recently (August 2015) been removed from debian.

Reviewers: zmike, devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3150
2015-10-06 13:13:01 -04:00
Ji-Youn Park ff6f6f198b ecore_x_keygrab: fix memory leak 2015-09-24 16:02:03 +08:30
Srivardhan Hebbar 6eefe25dcf ecore_x: remove useless assignment.
Summary:
The assignment of NULL will have no effect on the caller. So removed that statment.

Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3095

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-09-23 14:22:44 -07:00
Srivardhan Hebbar 205186da16 ecore_x: fixing memory leak on realloc.
Summary:
If realloc fails, it returns NULL. Then whatever the memory the ignore_list was pointing to would be leaked. So freeing it now.

Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: stefan_schmidt, cedric

Reviewed By: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3012

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-09-22 00:06:07 +02:00
ChunEon Park bca18f5f93 ecore_x: fix the memory leak.
@fix
2015-09-21 21:00:16 +09:00
ChunEon Park d6890c9ed5 Revert "ecore_x: remove dead code."
This reverts commit 7303fcee4d.

acutally the code was intended for compile warning.
2015-09-21 20:09:15 +09:00
ChunEon Park 7303fcee4d ecore_x: remove dead code.
remove ridiculous code.
2015-09-21 19:59:48 +09:00
ChunEon Park c5671efadb ecore_x: free the allocated memory after used.
XFixesInvertRegion doesn't free the xbound argument inside.

@fix
2015-09-21 19:49:10 +09:00
Carsten Haitzler 5b2baf173e efl - set thread names for internally created threads for debugging
@feature
2015-09-10 15:17:08 +09:00
Carsten Haitzler 66d53e5968 ecore x vsync - add in exynos checks and move kernel v checks inside
this adds asmung exynos driver as a whiteliested drm vsync driver.
this means 3.0 needs to work so move kernel ver checks inot each driver.

@feature
2015-09-08 22:00:33 +09:00
Mike Blumenkrantz 0efc83d64d ecore-x: add property member to Ecore_X_Event_Selection_Notify
@feature
2015-08-12 17:58:58 -04:00
Mike Blumenkrantz 5032cf0df3 ecore-x: provide property state in Ecore_X_Event_Window_Property
this event is not very useful without the state member.

@feature
2015-08-10 13:18:13 -04:00
Stefan Schmidt 6c8e07ff5f ecore_x: Add since 1.15 tag for keygrab API additions 2015-07-23 12:19:13 +02:00
Stefan Schmidt 016f34059c ecore_x: Add since 1.15 tag for keyrouter API additions 2015-07-23 12:19:13 +02:00
Mike Blumenkrantz 0b579f1f49 ecore-x: send last event time along with generic Ecore_X_Event_Client_Message
this won't necessarily be the same time that the client sent the message,
but at least it will provide a better reference point than 0
2015-07-21 18:12:54 -04:00
Carsten Haitzler 589fbd80cd ecore-x fix warning on unused function due to ifdefs 2015-07-09 15:45:15 +09:00
Mike Blumenkrantz 121e7be4b6 Revert "ecore-input: add keysym to Ecore_Event_Key struct"
This reverts commit c3f3c4eba8.

this was audited and found to be impractical due to portability concerns
2015-06-29 13:18:01 -04:00
Mike Blumenkrantz 476ebdc0a1 ecore-x: add ecore_x_keysym_get()
this is a less invasive solution for retrieving a keysym. X keysyms are
not portable, and so this function should not be used for any code which
is meant to run on other platforms.

@feature
2015-06-29 13:18:01 -04:00
Ji-Youn Park 4d41778251 ecore_x_xi2: remove build warning 2015-06-30 00:58:24 +09:00
Ji-Youn Park f74895c6b7 ecore_x_xi2: add small code to check device id
cancel event only can be dealed in touch device.
2015-06-30 00:02:47 +09:00
Ji-Youn Park bd6d7850dc ecore_x_xi2: fix only ecore input handler deals touch cancel event
X gives only one cancel event in one touch device even though several touch point.
move code related with touch cancel to input hander function
2015-06-29 23:09:33 +09:00
Ji-Youn Park 049b397a86 ecore_x_xi2: fix crash if device info is NULL.
_ecore_x_input_device_lookup can return NULL.
@fix
2015-06-26 13:42:56 +09:00