efreet: Fix resource leak
authorChristopher Michael <cp.michael@samsung.com>
Fri, 15 Mar 2019 12:58:17 +0000 (08:58 -0400)
committerYeongjong Lee <yj34.lee@samsung.com>
Tue, 2 Apr 2019 03:45:17 +0000 (12:45 +0900)
Summary:
Coverity reports that we leak 'exec' here when we return. Add
IF_FREE(exec) to remove the leak.

Fixes Coverity CID1399090

@fix

Depends on D8353

Reviewers: raster, cedric, zmike, bu5hm4n, stefan_schmidt

Reviewed By: cedric

Subscribers: #reviewers, #committers

Tags: #efl

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

src/lib/efreet/efreet_desktop_command.c

index c98ce0f..8c99102 100644 (file)
@@ -464,6 +464,7 @@ efreet_desktop_command_build(Efreet_Desktop_Command *command)
     }
     while ((l = eina_list_next(l)));
 
+    IF_FREE(exec);
     return execs;
 error:
     IF_FREE(exec);