Commit Graph

95 Commits

Author SHA1 Message Date
Shinwoo Kim 66c5729494 eeze: remove memory leak
Summary: udev_enumerate_new needs to call udev_enumerate_unref before leaving.

Reviewers: raster, Hermet, herb, jsuya

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D12280
2021-05-24 19:48:43 +09:00
Alastair Poole b02cef69d1 freebsd: eeze support if enabled.
ifr_netmask is not available on FreeBSD. On Linux ifr_addr is
same union.

Peter2121 did this work.
2021-04-10 08:58:38 +01:00
Marcel Hollerbach 046c5cd58e eeze_scanner: do not crash
the free logic here was wrong. The udev_device_get_parent results get
automatically unrefed when the original device is deleted.

This caused random segfaults when starting e.
2021-03-15 14:16:34 +01:00
Christopher Michael 95a88f5a6c eeze_disk: fix potential memory leak
If allocation for disk fails, then we leak memory from previously
called _new_device function.

This patch based on D12223 from akanad (Wonki Kim)

ref D12223
2021-02-25 10:05:26 -05:00
Christopher Michael 691621336a eeze_disk: Remove extra blank lines
NB: No functional changes
2021-02-25 09:57:47 -05:00
Shinwoo Kim ccf77acc22 eeze: fix a potention memory leak
Summary:
if udev device get parents fails, memory leaks.
this patch fixes the problem.

Reviewers: raster, Hermet, jsuya, herb, ali.alzyod, devilhorns

Reviewed By: ali.alzyod, devilhorns

Subscribers: ali.alzyod, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D12249
2021-02-17 10:18:43 +09:00
Wonki Kim 257dced038 eeze walk: fix a memory leaking
Summary:
there is a memory leak in a logic for walking along child-parent relation,
in case of device_get_sysattr_value failure.
this patch fixes the leak.

Change-Id: I95e9484b1549d1c794ec529c995af33da9b8a0ee

Reviewers: bu5hm4n, zmike

Subscribers: raster, SPAM-TeresaButler, vtorri, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D12224
2021-01-25 08:55:24 +00:00
Wonki Kim b1c9b8cec0 eeze_syspaty: fix a potention memory leak
Summary:
if udev device get sysname fails, memory leaks.
this patch fixes the problem.

Change-Id: I2d02a6e6eb98e9262255ab3c02cf99f347b8c5f9

Reviewers: bu5hm4n, Hermet, zmike

Reviewed By: Hermet

Subscribers: vtorri, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D12222
2020-12-24 11:48:53 +09:00
Wonki Kim 37cecd5413 eeze_net: fix a potentional memory leak case
Summary:
if `net` equals zero and `device` has allocated properly at the same time, memory leaks.
this patch fixes it.

Reviewers: Hermet, bu5hm4n, zmike

Reviewed By: Hermet

Subscribers: vtorri, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D12221
2020-12-24 11:43:28 +09:00
Elyes HAOUAS 1a9b5fcf70 Get rid of trailing whitespaces (7 / 14)
Remove trailing whitespaces
Differential Revision: https://phab.enlightenment.org/D12005
2020-06-23 10:30:05 +02:00
Marcel Hollerbach 8e3606698e refactor build
libraries are split into deps, external deps, and pub deps.
Evas engines are refactored to use the predefined engine deps.

this is preparation work for efl-one.

Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org>
Differential Revision: https://phab.enlightenment.org/D11806
2020-05-27 11:06:46 +02:00
Xavi Artigas 5b2d2a85b2 doxygen docs: Fix tons of invalid Doxygen commands
Mostly typos
2020-03-10 21:36:34 +01:00
Xavi Artigas 9f4b5458ea doxygen: fix duplicated toc sections 2020-02-28 11:44:19 +01:00
Stefan Schmidt 5888c7ee00 eeze: remove tizen module support from eeze sensor
This has been disabled since the move to meson and unlikely to have
built before with autotools either. Tizen never adopted this so we can
ease our maintenance burden here.

The Eeze sensor API itself is EAPI sadly and can't be removed. We will
keep the udev backend (temperature only) and the fake backend for
testing for now.

Signed-off-by: Stefan Schmidt <s.schmidt@samsung.com>
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D10805
2019-12-11 13:46:31 +01:00
Marcel Hollerbach e43f090265 cmake: remove!
This build was never complete and also was not maintained probebly.

It is also dropped in favour of meson which is cool, merged, works & is fast.

Differential Revision: https://phab.enlightenment.org/D7010
2018-12-20 20:07:26 +01:00
Marcel Hollerbach ba0630afda meson: support older udev systems
Differential Revision: https://phab.enlightenment.org/D7145
2018-10-11 17:11:36 +02:00
Alastair Poole 8974f98b1c eeze: Add buildsystem to list of dependencies.
Summary:
This fixing building E with EFL both using meson
build system. Previously missing symbols, which
this patch resolves.

Reviewers: bu5hm4n, raster

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7142
2018-10-04 12:41:46 +01:00
Marcel Hollerbach 46d464e5bf here comes meson
a new shiny buildtool that currently completes in the total of ~ 4 min..
1 min. conf time
2:30 min. build time
Where autotools takes:
1:50 min. conf time
3:40 min. build time.

meson was taken because it went quite good for enlightenment, and is a traction gaining system that is also used by other mayor projects. Additionally, the DSL that is defined my meson makes the configuration of the builds a lot easier to read.

Further informations can be gathered from the README.meson

Right now, bindings & windows support are missing.

It is highly recommented to use meson 0.48 due to optimizations in meson
that reduced the time the meson call would need.

Co-authored-by: Mike Blumenkrantz <zmike@samsung.com>

Differential Revision: https://phab.enlightenment.org/D7012
Depends on D7011
2018-10-02 17:22:50 +02:00
Yeongjong Lee 02d83ebcd4 docs: Fix typos in API reference doc and comments.
Reviewers: Hermet, segfaultxavi

Reviewed By: Hermet, segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6948
2018-08-31 17:45:31 +09:00
Marcel Hollerbach 014df3d710 eeze: use new bs static lib 2018-02-17 21:17:58 +01:00
Mike Blumenkrantz 5760b3f335 eeze: simplify watch code and make it fork-safe
avoid reads from parent process's udev fds
2018-02-02 16:59:44 -05:00
Jean-Philippe Andre ff24ac2d6d efl: Reset ecore event types on init
This fixes cycles of init/shutdown/init where ecore event types would
become invalid, since they are now stored in a dynamic array rather than
a statically stored array.

The risk here is that if a module of EFL tends to init/shutdown in a
"normal" scenario then the event type array will grow in a leaking
manner. This could be fixed by resetting those event ID's only when the
loop actually exits (EFL_EVENT_DEL on the main loop). I'm not using
EFL_EVENT_DEL in this patch as this would add too many event callbacks
to the main loop object, which may result in slightly slower event calls
to it, affecting the overall performance.
2017-12-19 11:14:37 +09:00
Chris Michael af4af300af eeze: Remove unused device variables
As we do not ever use the udev_devices created from
udev_device_new_from_syspath in these functions, remove them.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2017-12-14 07:35:07 -05:00
Chris Michael 5f7d942253 eeze: Don't leak udev enumeration
If we cannot create a new udev device, then we should free the
previously created udev enumeration from above.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2017-12-14 07:31:39 -05:00
Ross Vandegrift 71e5c74eb6 efl: drop deprecated Encoding key from desktop files
Summary:
The Encoding key is no longer required, all desktop files are assumed to
be UTF-8 encoded.  See details at:
https://standards.freedesktop.org/desktop-entry-spec/1.1/apc.html

Fix various typos and misspellings

lintian, Debian's package checker, uses strings to check for common typos
in compiled binaries.  This change fixes the ones it identified in 1.20.6.

Reviewers: cedric

Reviewed By: cedric

Subscribers: cedric, jpeg

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

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2017-12-13 10:27:48 -08:00
Carsten Haitzler 08a69d2284 eeze_disk - remove redundant if check already done
removes redundant fi check. not a bug but analysers dont like it and
it is redundant

found by PVS studio
2017-07-29 10:56:53 +09:00
Carsten Haitzler d532f28284 eeze disk - remove uneeded extra check for test var
test for non null already done above, so test must obviously be null
here so no need to check. analysers dont like this but it's not a bug.
make them happy thought

found by PVS studio
2017-07-29 10:37:51 +09:00
Cedric BAIL ff3c6f394e eeze: avoid crash during shutdown due to Ecore_Event queue. 2017-03-09 16:17:58 -08:00
Gustavo Sverzut Barbieri 8dc853f230 ifdef RUN_IN_TREE logic.
This logic is only needed for autotools, cmake will replicate the
installation file structure and thus eina_prefix works out of box.
2017-02-03 12:36:38 -02:00
Marcel Hollerbach 3c0fe3ca3c cmake: add eeze
there is currently a bug in the testsuite which needs to change,
otherwise modules cannot be loaded. The code acutally runs when its
installed and EFL_RUN_IN_TREE is not set.
2017-02-03 10:59:04 +01:00
Amitesh Singh a17909b007 eeze: remove trailing whitespaces 2016-09-07 09:48:39 +05:30
Amitesh Singh a2e3b8ad13 eeze: add support of GPIO sysfs detection and watch.
This adds support for detection and watch of GPIO pins in /sys/class/gpio/*
This detects both gpiochip<N> & gpio<N>.

@feature
2016-09-06 20:42:26 +05:30
Stefan Schmidt 969bd17ab7 eeze: remove trailing whitespace
Nothing to see here, just stumbled over it when reading through the file.
2016-03-11 17:59:46 +01:00
Nicolas Aguirre 95a494c73e eeze: add case for Graphics subsystems in eeze_udev_find_by_type
Add code to detect Graphics subsystem, i.e framebuffer devices
/dev/fbX in eeze. This will be used in Ecore-Fb to detect the
framebuffers present on the system.

@feature

Signed-off-by: Nicolas Aguirre <aguirre.nicolas@gmail.com>
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2016-02-10 10:46:45 -08:00
Chris Michael 684d5180c3 eeze: Fix eeze_udev_find_by_subsystem_sysname function
This function was severly broken when used for finding devices of a
particular subsystem. Previously, this function would return every
device in the system, regardless if subsystem or sysname was passed in.
This patch fixes the issue by adding udev_enumerate matches before we
scan for devices. This way, when we enumerate the scan results, we now
get only devices that match the subsystem (if supplied).

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-01-29 13:46:30 -05:00
Ryuan Choi bddce0b650 Eeze: Fix build break with --disable-libmount
While compiling eeze_disk_dummy.c, eeze_mount_tabs_watch does not have visibility
because EAPI is cleared by Ecore.h in Eeze_Disk.h.
2015-08-01 00:17:37 +09:00
Cedric BAIL e2f69adcf0 eeze: remove the need to order the header correctly for Windows. 2015-05-07 09:53:10 +02:00
woochan lee 48f4f1b837 Eeze.h: Delete white space.
Summary: Delete white space in Eeze.h

Reviewers: cedric, Sergeant_Whitespace

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D2246
2015-04-02 14:47:43 +02:00
Chris Michael fe77fb6c34 eeze: Fix issue of eeze_udev_watch_add not getting events for drm
Summary: This fixes eeze_udev_watch_add for DRM events, Previously, we
were not getting a watch callback fired due to using the wrong
subsystem device type in
udev_monitor_filter_add_match_subsystem_devtype.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-03-23 12:14:45 -04:00
Daniel Kolesa 2b8bc02e12 edje, eeze: compiler portability (use full ternary operator) 2015-02-13 14:20:32 +00:00
Daniel Juyung Seo 694c77826b eeze: Fix unused variable build warning.
lib/eeze/eeze_udev_syspath.c: In function 'eeze_udev_syspath_set_sysattr':
lib/eeze/eeze_udev_syspath.c:206:38: warning: unused parameter 'value' [-Wunused-parameter] double value)
                                                                     ^
2014-12-29 23:18:03 +09:00
Chris Michael 9778443f02 eeze: Add API function for eeze_udev_find_by_subsystem_sysname
Summary: This adds an API function to find a device by
subsystem_sysname. This is needed for the port of ecore_drm to use
libinput.

@feature

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-12-09 15:10:43 -05:00
Chris Michael 34f9c63862 eeze: Add API function declaration for find_by_subsystem_sysname
Summary: This adds an API function declaration for
eeze_udev_find_by_subsystem_sysname function which is needed for the
porting of ecore_drm to use libinput

@feature

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-12-09 15:09:25 -05:00
Shinwoo Kim a15ec56e4f Check return value of udev_device_get_sysattr_value(); before using atoi();
Summary: udev_device_get_sysattr_value(); could return NULL, and using atoi(); with NULL make system crash

Test Plan: It is hard to make a case to retun NULL. I got this from aging test of a product.

Reviewers: cedric, raster, seoz, woohyun, Hermet, jaehwan

Subscribers: cedric, seoz

Differential Revision: https://phab.enlightenment.org/D1687
2014-11-29 15:53:24 +09:00
Nicolas Aguirre ad41ba380e eeze: add documentation for Eeze_Version structure. 2014-10-20 18:01:59 +02:00
Carsten Haitzler 22bf1b3db2 eeze - sensors - ints for sensor events were decld in .h - and never .c
this was bad - we never had eeze sensor events declared inside eeze
so they were only in the .h - they could be diff symbols and thus
valuses may not match. big @fix - it worked by luck, not design.
2014-10-01 16:32:20 +09:00
Chris Michael 1175bb47b9 eeze: Add ifdef trap for older udev version
Summary: This adds an ifdef trap for older versions of libudev which
do not provide udev_device_set_sysattr_value function. This fixes
broken EFL compile with older versions of udev.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-30 08:38:57 -04:00
vivek 4483ef20d3 eeze: Added API to get sysattr list of a device
Summary:
Added eeze_udev_syspath_get_sysattr_list API to get
list of sysattr of a device. It returns Eina list containing list
of system attributes.

Signed-off-by: vivek <vivek.ellur@samsung.com>

Reviewers: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1492
2014-09-26 08:38:36 -04:00
vivek f15f875fa9 eeze: Added API to set sysattr values
Summary:
Added eeze_udev_set_sysattr API to set value of various
system attributes of a device

Signed-off-by: vivek <vivek.ellur@samsung.com>

Reviewers: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1491
2014-09-26 08:06:05 -04:00
Chris Michael 763b210f4e eeze: Fix missing break in switch(s)
Summary: Fixes Coverity CID1240226, CID1240225

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-23 19:19:47 -04:00