aboutsummaryrefslogtreecommitdiffstats
path: root/action.c
diff options
context:
space:
mode:
authorgotmor <gotmor@f2baff5b-bf2c-0410-a398-912abdc3d8b2>2007-06-01 11:28:57 +0000
committergotmor <gotmor@f2baff5b-bf2c-0410-a398-912abdc3d8b2>2007-06-01 11:28:57 +0000
commitb25989d6d21e66f36102fcdc87cff3ffdcb4eeec (patch)
tree3d383c6239dc38e972a5f93ff1bf7bce52ac34fc /action.c
parent8031980e8d2d2310622013e0bdf33e8e9741f9bf (diff)
downloaddzen-b25989d6d21e66f36102fcdc87cff3ffdcb4eeec.tar.gz
dzen-b25989d6d21e66f36102fcdc87cff3ffdcb4eeec.zip
0.3.0 - switch to select()
git-svn-id: http://dzen.googlecode.com/svn/trunk@42 f2baff5b-bf2c-0410-a398-912abdc3d8b2
Diffstat (limited to 'action.c')
-rw-r--r--action.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/action.c b/action.c
index 7203a73..ad00d10 100644
--- a/action.c
+++ b/action.c
@@ -133,9 +133,10 @@ fill_ev_table(char *input)
}
if(str4 == kommatoken && str4 != token && eid != -1) {
ev_table[eid].isset = 1;
- ev_table[eid].action[i] = malloc(sizeof(As));
- if((ah = (void *)get_action_handler(dptoken)))
+ if((ah = (void *)get_action_handler(dptoken))) {
+ ev_table[eid].action[i] = emalloc(sizeof(As));
ev_table[eid].action[i]->handler= get_action_handler(dptoken);
+ }
i++;
}
else if(str4 != token && eid != -1 && ah) {
@@ -147,7 +148,7 @@ fill_ev_table(char *input)
}
k=0;
}
- ev_table[eid].action[i] = malloc(sizeof(As));
+ ev_table[eid].action[i] = emalloc(sizeof(As));
ev_table[eid].action[i]->handler = NULL;
i=0;
}