summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2018-06-21 08:03:44 +0200
committerThomas Haller <thaller@redhat.com>2018-06-27 09:14:36 +0200
commit9e20ba6646634be373ed91136000abf687c9af57 (patch)
tree6a15b2bab1a71a9395a6e5a77174fa7222c47a4c
parent191c9c7f0d941a34446d26637db535a3ec1c57d8 (diff)
downloadNetworkManager-9e20ba6646634be373ed91136000abf687c9af57.tar.gz
main: free error variable in main() at exit
Just try to free everything that was allocated. Don't leak error in case of failure.
-rw-r--r--src/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index c1267b275d..5cb7e785bf 100644
--- a/src/main.c
+++ b/src/main.c
@@ -227,7 +227,7 @@ main (int argc, char *argv[])
gboolean success = FALSE;
NMManager *manager = NULL;
NMConfig *config;
- GError *error = NULL;
+ gs_free_error GError *error = NULL;
gboolean wrote_pidfile = FALSE;
char *bad_domains = NULL;
NMConfigCmdLineOptions *config_cli;