char *ptr = NULL;
event_type = strtok_r(msg, ":", &ptr);
+ if (event_type == NULL) {
+ ACCOUNT_ERROR("strtok_r() failed");
+ goto END;
+ }
+
id = strtok_r(NULL, ":", &ptr);
+ if (id == NULL) {
+ ACCOUNT_ERROR("strtok_r() failed");
+ goto END;
+ }
ACCOUNT_SLOGD("msg(%s), event_type(%s), id(%s)", msg, event_type, id);
if (tmp->account_subscription_callback)
tmp->account_subscription_callback(event_msg, account_id, tmp->user_data);
+END:
_ACCOUNT_FREE(msg);
}
}