projects
/
platform
/
upstream
/
connman.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a0a70f0
)
Fix SEGV at first startup
author
David Woodhouse
<dwmw2@infradead.org>
Fri, 9 Jul 2010 21:45:24 +0000
(23:45 +0200)
committer
Samuel Ortiz
<sameo@linux.intel.com>
Fri, 9 Jul 2010 21:45:24 +0000
(23:45 +0200)
connman_wifi_load_ssid() can return NULL. Best not to dereference that.
This fixes Meego's bug #3787.
plugins/supplicant.c
patch
|
blob
|
history
diff --git
a/plugins/supplicant.c
b/plugins/supplicant.c
index
276fd91
..
85016ba
100644
(file)
--- a/
plugins/supplicant.c
+++ b/
plugins/supplicant.c
@@
-610,7
+610,13
@@
static void add_interface_reply(DBusPendingCall *call, void *user_data)
connman_device_set_powered(task->device, TRUE);
+ dbus_message_unref(reply);
+
+ dbus_pending_call_unref(call);
+
hex_ssids = connman_wifi_load_ssid();
+ if (hex_ssids == NULL)
+ return;
for (i = 0; hex_ssids[i]; i++) {
unsigned char *ssid;
@@
-635,10
+641,6
@@
static void add_interface_reply(DBusPendingCall *call, void *user_data)
g_strfreev(hex_ssids);
- dbus_message_unref(reply);
-
- dbus_pending_call_unref(call);
-
return;
failed: