From: Nishant Chaprana Date: Wed, 30 Sep 2020 10:10:18 +0000 (+0530) Subject: [Fix][plugin/ethernet] SVACE warning DEREF_AFTER_NULL X-Git-Tag: accepted/tizen/6.0/unified/20201030.105121~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F67%2F245067%2F2;p=platform%2Fupstream%2Fconnman.git [Fix][plugin/ethernet] SVACE warning DEREF_AFTER_NULL Change-Id: Ie3a9044de3be7ce46d05052920f9d5b5d99cd15f Signed-off-by: Nishant Chaprana --- diff --git a/packaging/connman.spec b/packaging/connman.spec index a8904e2..0957d3d 100644 --- a/packaging/connman.spec +++ b/packaging/connman.spec @@ -5,7 +5,7 @@ Name: connman Version: 1.37 -Release: 44 +Release: 45 License: GPL-2.0+ Summary: Connection Manager Url: http://connman.net diff --git a/plugins/ethernet.c b/plugins/ethernet.c index 57d6542..2a91e2f 100644 --- a/plugins/ethernet.c +++ b/plugins/ethernet.c @@ -437,7 +437,10 @@ static void eth_dev_remove(struct connman_device *device) connman_device_set_data(device, NULL); #if defined TIZEN_EXT && defined TIZEN_EXT_EAP_ON_ETHERNET - if (ethernet && ethernet->interface) { + if (!ethernet) + return; + + if (ethernet->interface) { g_supplicant_interface_remove(ethernet->interface, NULL, NULL); ethernet->interface = NULL; }