The `data` from '_ecore_evas_msg_handle' doesn't have null-character.
If you use this data for strcmp, it may corrupt memory.
Change-Id: I715ef2fe35a04f5b0992aabd5249d4d9dc0f5ef8
_ecore_evas_msg_handle(Ecore_Evas *ee, int msg_domain, int msg_id, void *data, int size)
{
callback_counter++;
- if (size == strlen(msg_data) && strcmp(data,msg_data) == 0)
+ if (size == strlen(msg_data) && strncmp(msg_data, data, size) == 0)
{
callback_msg = EINA_TRUE;
}
_ecore_evas_msg_parent_handle(Ecore_Evas *ee, int msg_domain, int msg_id, void *data, int size)
{
callback_counter++;
- if (size == strlen(msg_data) && strcmp(data,msg_data) == 0)
+ if (size == strlen(msg_data) && strncmp(msg_data, data, size) == 0)
{
callback_msg = EINA_TRUE;
}
_ecore_evas_msg_parent_handle(Ecore_Evas *ee, int msg_domain, int msg_id, void *data, int size)
{
callback_counter++;
- if (size == strlen(msg_data) && strcmp(data,msg_data) == 0)
+ if (size == strlen(msg_data) && strncmp(msg_data, data, size) == 0)
{
callback_msg = EINA_TRUE;
}
_ecore_evas_msg_handle(Ecore_Evas *ee, int msg_domain, int msg_id, void *data, int size)
{
callback_counter++;
- if (size == strlen(msg_data) && strcmp(data,msg_data) == 0)
+ if (size == strlen(msg_data) && strncmp(msg_data,data,size) == 0)
{
callback_msg = EINA_TRUE;
}