diff options
author | Samuel Ortiz <sameo@linux.intel.com> | 2009-06-29 21:17:39 +0200 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2009-06-30 03:08:42 +0200 |
commit | 7404d68b001a29e96fcf11727def2ac53e40d2df (patch) | |
tree | bb28f3b0e5e8c258eca8b796204457b71891d1a3 /src/connection.c | |
parent | a7b3cd5992de6abfb5efcd77658887e2eddfdba0 (diff) | |
download | connman-7404d68b001a29e96fcf11727def2ac53e40d2df.tar.gz connman-7404d68b001a29e96fcf11727def2ac53e40d2df.tar.bz2 connman-7404d68b001a29e96fcf11727def2ac53e40d2df.zip |
Check for active_gateway being non NULL before dereferencing it
Diffstat (limited to 'src/connection.c')
-rw-r--r-- | src/connection.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/connection.c b/src/connection.c index d057d8a6..b20a5a19 100644 --- a/src/connection.c +++ b/src/connection.c @@ -654,6 +654,6 @@ void __connman_connection_update_gateway(void) active_gateway = find_active_gateway(); default_gateway = find_default_gateway(); - if (active_gateway != default_gateway) + if (active_gateway && active_gateway != default_gateway) del_route(active_gateway->element, active_gateway->gateway); } |