summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/bin/dnd.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/bin/dnd.c b/src/bin/dnd.c
index 01daa5c..f68724a 100644
--- a/src/bin/dnd.c
+++ b/src/bin/dnd.c
@@ -172,12 +172,16 @@ Eina_Bool
172_cb_drop(void *data, Evas_Object *o EINA_UNUSED, Elm_Selection_Data *ev) 172_cb_drop(void *data, Evas_Object *o EINA_UNUSED, Elm_Selection_Data *ev)
173{ 173{
174 Evas_Object *win = data; 174 Evas_Object *win = data;
175 char **plist, **p, *esc; 175 char **plist, **p, *esc, *tmp;
176 176
177 if (!ev->data) 177 if (!ev->data)
178 return EINA_TRUE; 178 return EINA_TRUE;
179 179
180 plist = eina_str_split((char *) ev->data, "\n", -1); 180 tmp = malloc(ev->len + 1);
181 if (!tmp) return EINA_TRUE;
182 memcpy(tmp, ev->data, ev->len);
183 tmp[ev->len] = 0;
184 plist = eina_str_split(tmp, "\n", -1);
181 for (p = plist; *p != NULL; ++p) 185 for (p = plist; *p != NULL; ++p)
182 { 186 {
183 esc = _escape_parse(*p); 187 esc = _escape_parse(*p);
@@ -198,6 +202,7 @@ _cb_drop(void *data, Evas_Object *o EINA_UNUSED, Elm_Selection_Data *ev)
198 202
199 free(*plist); 203 free(*plist);
200 free(plist); 204 free(plist);
205 free(tmp);
201 206
202 if (!pending_dir) 207 if (!pending_dir)
203 _dnd_finish(win); 208 _dnd_finish(win);