sim: Reset mnc_length when removing SIM
authorDenis Kenzior <denkenz@gmail.com>
Mon, 23 Aug 2010 18:20:54 +0000 (13:20 -0500)
committerDenis Kenzior <denkenz@gmail.com>
Mon, 23 Aug 2010 19:29:22 +0000 (14:29 -0500)
In case the next SIM doesn't have it or something else weird happens.

src/sim.c

index dba1e15..839edd5 100644 (file)
--- a/src/sim.c
+++ b/src/sim.c
@@ -2013,6 +2013,8 @@ static void sim_free_state(struct ofono_sim *sim)
                sim->efest = NULL;
                sim->efest_length = 0;
        }
+
+       sim->mnc_length = 0;
 }
 
 void ofono_sim_inserted_notify(struct ofono_sim *sim, ofono_bool_t inserted)