git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/e_dbus@64955
7cbeb6ba-43b4-40fd-8cce-
4c39aea84d33
int bits_per_sample;
int channels;
unsigned char *data;
- Eina_Bool free_data : 1;
};
struct E_Notification
dbus_message_iter_get_fixed_array(&arr, &(byte_array), &array_len);
img->data = malloc(array_len);
memcpy(img->data, byte_array, array_len);
- img->free_data = EINA_TRUE;
return img;
}
img->height = h;
img->bits_per_sample = 8;
img->has_alpha = EINA_TRUE;
- img->free_data = EINA_TRUE;
rowstride = evas_object_image_stride_get(obj);
for (y = 0; y < img->height; y++)
EAPI void
e_notification_image_free(E_Notification_Image *img)
{
- if (img->data && img->free_data) free(img->data);
- if (img) free(img);
+ if (!img) return;
+ free(img->data);
+ free(img);
}
static Eina_Bool