raster pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=273ec4168704dd3a599c97be4a19897e6e629e7f

commit 273ec4168704dd3a599c97be4a19897e6e629e7f
Author: Carsten Haitzler (Rasterman) <ras...@rasterman.com>
Date:   Thu Apr 23 01:00:10 2020 +0100

    e actions - handle params not being provided by user bindings
    
    fix CID 1425456
---
 src/bin/e_actions.c | 20 +++++++++++++-------
 1 file changed, 13 insertions(+), 7 deletions(-)

diff --git a/src/bin/e_actions.c b/src/bin/e_actions.c
index 7de7bf79d..8b51cb103 100644
--- a/src/bin/e_actions.c
+++ b/src/bin/e_actions.c
@@ -2688,10 +2688,13 @@ _delayed_action_cb_timer(void *data)
 
    da = data;
    da->timer = NULL;
-   act = e_action_find(da->delayed.action);
-   if (act)
+   if (da->delayed.action)
      {
-        if (act->func.go) act->func.go(da->obj, da->delayed.params);
+        act = e_action_find(da->delayed.action);
+        if (act)
+          {
+             if (act->func.go) act->func.go(da->obj, da->delayed.params);
+          }
      }
    _delayed_actions = eina_list_remove(_delayed_actions, da);
    _delayed_action_free(da);
@@ -2703,10 +2706,13 @@ _delayed_action_do(Delayed_Action *da)
 {
    E_Action *act;
 
-   act = e_action_find(da->def.action);
-   if (act)
+   if (da->def.action)
      {
-        if (act->func.go) act->func.go(da->obj, da->def.params);
+        act = e_action_find(da->def.action);
+        if (act)
+          {
+             if (act->func.go) act->func.go(da->obj, da->def.params);
+          }
      }
 }
 
@@ -2718,7 +2724,7 @@ _delayed_action_list_parse_action(const char *str, double 
*delay, const char **a
    const char *p;
 
    buf[0] = 0;
-   sscanf(str, "%10s %1000s", fbuf, buf);
+   if (sscanf(str, "%10s %1000s", fbuf, buf) != 2) return;
    *action = eina_stringshare_add(buf);
    *delay = atof(fbuf);
    p = strchr(str, ' ');

-- 


Reply via email to