summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.com>2008-12-09 13:46:00 +0000
committerOlivier Blin <oblin@mandriva.com>2008-12-09 13:46:00 +0000
commitb6f9a0cb8dafefd67c991ca54b401789d9f75172 (patch)
tree06e1e00cddaaf7fe0ae82f79cbced2eca4f232a7
parentd6afae637149304c3a48088e6666585dc2700cd2 (diff)
downloadmandi-b6f9a0cb8dafefd67c991ca54b401789d9f75172.tar
mandi-b6f9a0cb8dafefd67c991ca54b401789d9f75172.tar.gz
mandi-b6f9a0cb8dafefd67c991ca54b401789d9f75172.tar.bz2
mandi-b6f9a0cb8dafefd67c991ca54b401789d9f75172.tar.xz
mandi-b6f9a0cb8dafefd67c991ca54b401789d9f75172.zip
fix recv size
-rw-r--r--src/plugins/wireless/plugin.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/wireless/plugin.c b/src/plugins/wireless/plugin.c
index feb12de..14eab42 100644
--- a/src/plugins/wireless/plugin.c
+++ b/src/plugins/wireless/plugin.c
@@ -63,7 +63,7 @@ static void deinit(plugin_t *plugin, DBusConnection *connection) {
static void handle_incoming(plugin_t *plugin, DBusConnection *connection) {
struct wpa_ctrl *ctrl_conn = (struct wpa_ctrl *) plugin->priv;
char buf[2048];
- size_t len;
+ size_t len = sizeof(buf);
wpa_ctrl_recv(ctrl_conn, buf, &len);
buf[len] = '\0';
printf("received event: %s\n", buf);