Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Looks like trigger_udev_sysname variable stays valid only because udev_device_new_from_syspath() return value is leaked in trigger_init(). Take a copy of udev_device_get_sysname() return value instead on relying on borrowed string pointer staying valid. Remove all mid-function returns, release unneeded resources on success, and all acquired resources in case of failure. Having a boolean function return false on success / true on failure is a bit confusing, so rectify that while at it. Signed-off-by: Simo Piiroinen <simo.piiroinen@jollamobile.com>
- Loading branch information
Showing
2 changed files
with
76 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters