summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@osg.samsung.com>2015-08-13 14:43:04 -0400
committerMike Blumenkrantz <zmike@osg.samsung.com>2015-08-13 14:46:02 -0400
commit8d4b06617fd9a9a71e08a63063d739ee56ef4f36 (patch)
tree2929c54be292127015a55cff06c9704f3d7e863f
parent4b25721a1d5b1a895ca1cf7831e566c67a44894c (diff)
use event length instead of strlen() when dropping something into a terminal
the data member of Elm_Selection_Data may not be nul terminated, so any string operation on this is liable to crash
-rw-r--r--src/bin/termio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bin/termio.c b/src/bin/termio.c
index 31ddca4..9992b22 100644
--- a/src/bin/termio.c
+++ b/src/bin/termio.c
@@ -5664,7 +5664,7 @@ _smart_cb_drop(void *data, Evas_Object *o EINA_UNUSED, Elm_Selection_Data *ev)
5664 evas_object_smart_callback_call(obj, "popup", ev->data); 5664 evas_object_smart_callback_call(obj, "popup", ev->data);
5665 } 5665 }
5666 else 5666 else
5667 termpty_write(sd->pty, ev->data, strlen(ev->data)); 5667 termpty_write(sd->pty, ev->data, ev->len);
5668 return EINA_TRUE; 5668 return EINA_TRUE;
5669} 5669}
5670#endif 5670#endif