session: No need to free NULL list
authorDaniel Wagner <daniel.wagner@bmw-carit.de>
Wed, 19 Sep 2012 12:50:02 +0000 (14:50 +0200)
committerDaniel Wagner <daniel.wagner@bmw-carit.de>
Thu, 27 Sep 2012 08:28:27 +0000 (10:28 +0200)
src/session.c

index c7c72a5..96b2e59 100644 (file)
@@ -325,11 +325,8 @@ static GSList *session_allowed_bearers_any(void)
        GSList *list = NULL;
 
        info = g_try_new0(struct bearer_info, 1);
-       if (info == NULL) {
-               g_slist_free(list);
-
+       if (info == NULL)
                return NULL;
-       }
 
        info->name = g_strdup("");
        info->match_all = TRUE;