Index: common/phones/atgen.c =================================================================== RCS file: /sources/gnokii/gnokii/common/phones/atgen.c,v retrieving revision 1.149 diff -u -p -r1.149 atgen.c --- common/phones/atgen.c 6 Jul 2007 21:04:27 -0000 1.149 +++ common/phones/atgen.c 7 Jul 2007 01:15:49 -0000 @@ -1430,7 +1430,8 @@ static gn_error ReplyGetBattery(int mess if (!strncmp(buf.line1, "AT+CBC", 6) && !strncmp(buf.line2, "+CBC: ", 6)) { if (data->battery_level) { - *(data->battery_unit) = GN_BU_Percentage; + if (data->battery_unit) + *(data->battery_unit) = GN_BU_Percentage; pos = strchr(buf.line2, ','); if (pos) { pos++;