G1: move chat handling into enable callback
authorAndres Salomon <dilinger@collabora.co.uk>
Wed, 30 Sep 2009 03:53:59 +0000 (23:53 -0400)
committerDenis Kenzior <denkenz@gmail.com>
Wed, 30 Sep 2009 04:04:24 +0000 (23:04 -0500)
commit4decda3f7f359559493d0154a96ef6b1654a3edc
treed0fe2a959f146aa0b47c6b1c54741aaab1f8b5cf
parent128d129ef5b02525e0688feffe67a5a2c739a2e4
G1: move chat handling into enable callback

This updates the g1 code to create the GAtChat object in the enable() callback,
and to unref it in the disable() callback.  This is more in line with what
the other plugins do, and as a bonus fixes a segfault when powering down
the G1 modem..

Signed-off-by: Andres Salomon <dilinger@collabora.co.uk>
plugins/g1.c