req->mw = mw;
req->mailbox = mailbox;
string_to_phone_number(number, &req->number);
- req->msg = dbus_message_ref(msg);
+ req->msg = msg ? dbus_message_ref(msg) : NULL;
sim_adn_build(efmbdn, req->mw->efmbdn_length, &req->number, NULL);
indication = present;
mw->messages[type].indication = present;
- if (!mw_message_waiting_property_name[type])
+ if (mw_message_waiting_property_name[type])
ofono_dbus_signal_property_changed(conn, path,
MESSAGE_WAITING_INTERFACE,
mw_message_waiting_property_name[type],
mw->messages[type].message_count = messages;
- if (!mw_message_waiting_property_name[type])
+ if (mw_message_waiting_property_name[type])
ofono_dbus_signal_property_changed(conn, path,
MESSAGE_WAITING_INTERFACE,
mw_message_count_property_name[type],