diff options
author | Denis Kenzior <denkenz@gmail.com> | 2010-12-02 14:23:35 -0600 |
---|---|---|
committer | Denis Kenzior <denkenz@gmail.com> | 2010-12-03 08:01:10 -0600 |
commit | 4c2bd38f7f9a47de69232564eda7adf4b7ca2adb (patch) | |
tree | 07360f6fcb00312ec3bf1199d1a70c69a9dad14e /plugins/ste.c | |
parent | 6befb8290d72bfa037be697e27008cbb9749f862 (diff) | |
download | ofono-4c2bd38f7f9a47de69232564eda7adf4b7ca2adb.tar.bz2 |
ste: Minor style fixes
Diffstat (limited to 'plugins/ste.c')
-rw-r--r-- | plugins/ste.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/ste.c b/plugins/ste.c index 8bebfa48..ae6c8192 100644 --- a/plugins/ste.c +++ b/plugins/ste.c @@ -191,6 +191,7 @@ static GIOChannel *ste_create_channel(struct ofono_modem *modem) interface = ofono_modem_get_string(modem, "Interface"); if (interface) { struct ifreq ifreq; + memset(&ifreq, 0, sizeof(ifreq)); strcpy(ifreq.ifr_name, interface); err = setsockopt(fd, SOL_SOCKET, @@ -227,6 +228,7 @@ static GIOChannel *ste_create_channel(struct ofono_modem *modem) close(fd); return NULL; } + g_io_channel_set_close_on_unref(channel, TRUE); return channel; @@ -246,7 +248,7 @@ static int ste_enable(struct ofono_modem *modem) data->chat = g_at_chat_new_blocking(channel, syntax); g_at_chat_send(data->chat, "AT&F E0 V1 X4 &C1 +CMEE=1", - NULL, NULL, NULL, NULL); + NULL, NULL, NULL, NULL); g_io_channel_unref(channel); g_at_syntax_unref(syntax); |