ajwillia-ms pushed a commit to branch master.

http://git.enlightenment.org/tools/edi.git/commit/?id=22cfc584d696e0439c90d52ebbeff07c4b0426a1

commit 22cfc584d696e0439c90d52ebbeff07c4b0426a1
Author: Kelly Wilson <[email protected]>
Date:   Sun Feb 1 09:09:25 2015 -0700

    Edi_editor.c: Fix segfault
    
    Fix a segfault when opening a file in a new window and then pressing a key 
without any other interaction. Simply check if item is null and return without 
action if it is.
---
 src/bin/editor/edi_editor.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/bin/editor/edi_editor.c b/src/bin/editor/edi_editor.c
index 51cf60a..613c610 100644
--- a/src/bin/editor/edi_editor.c
+++ b/src/bin/editor/edi_editor.c
@@ -172,6 +172,10 @@ _smart_cb_key_down(void *data EINA_UNUSED, Evas *e 
EINA_UNUSED,
    shift = evas_key_modifier_is_set(ev->modifiers, "Shift");
 
    item = edi_mainview_item_current_get();
+
+   if (!item)
+     return;
+
    content = elm_object_item_content_get(item->view);
    editor = (Edi_Editor *)evas_object_data_get(content, "editor");
 

-- 


Reply via email to