Fix Svace issue 76/269076/2 submit/tizen/20220110.224444
authorAnuj Jain <anuj01.jain@samsung.com>
Fri, 7 Jan 2022 08:01:04 +0000 (13:31 +0530)
committerAnuj Jain <anuj01.jain@samsung.com>
Fri, 7 Jan 2022 10:05:31 +0000 (15:35 +0530)
This patch fixes Svace issue:
474931: DEREF_OF_NULL.RET.STAT

Change-Id: Id93e55f8beffba9a35e899a9c5be33d715bfc8dc
Signed-off-by: Anuj Jain <anuj01.jain@samsung.com>
profiles/audio/a2dp.c

index d2047cd..dc1b7ef 100644 (file)
@@ -669,7 +669,7 @@ static gboolean endpoint_setconf_ind(struct avdtp *session,
                DBG("Source %p: Set_Configuration_Ind", sep);
 
        setup = a2dp_setup_get(session);
-       if (!session)
+       if (!setup)
                return FALSE;
 
        a2dp_sep->stream = stream;