forked from enlightenment/efl
ecore_evas: do not leak allocated memory in error case
This commit is contained in:
parent
33203a9764
commit
5689ce8bfa
|
@ -5570,17 +5570,17 @@ ecore_evas_selection_set(Ecore_Evas *ee, unsigned int seat, Ecore_Evas_Selection
|
|||
|
||||
INF("Selection set on seat %d in buffer %d", seat, buffer);
|
||||
|
||||
buffers = _fetch_selection_buffers_of_seat(ee, seat, EINA_TRUE);
|
||||
|
||||
if (content)
|
||||
available_type = eina_content_possible_conversions(content);
|
||||
|
||||
if (buffer == ECORE_EVAS_SELECTION_BUFFER_DRAG_AND_DROP_BUFFER)
|
||||
{
|
||||
ERR("You cannot set a selection with this API, please use the API to start a drag operation");
|
||||
return EINA_FALSE;
|
||||
}
|
||||
|
||||
buffers = _fetch_selection_buffers_of_seat(ee, seat, EINA_TRUE);
|
||||
|
||||
if (content)
|
||||
available_type = eina_content_possible_conversions(content);
|
||||
|
||||
success = CALL(selection_claim)(ee, seat, buffer, _iterator_to_array(available_type, content ? eina_content_type_get(content) : NULL), content ? _deliver_cb : NULL, content ? _cancel_cb : NULL);
|
||||
if (success)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue