diff options
| author | Dana Jansens <danakj@orodu.net> | 2003-03-19 04:22:29 +0000 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2003-03-19 04:22:29 +0000 |
| commit | e4fe6da48c7ddb14639ab91f8532e89b16e72deb (patch) | |
| tree | 6cb19c97e81cbe0162a14c961b8a243b54a3c509 /plugins/mouse | |
| parent | 83e86fa0b632a8c3e41eb1030b32f3dbc21c21d7 (diff) | |
dont clean up nulls
Diffstat (limited to 'plugins/mouse')
| -rw-r--r-- | plugins/mouse/mouse.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/mouse/mouse.c b/plugins/mouse/mouse.c index 5dd39db3..dfdde6af 100644 --- a/plugins/mouse/mouse.c +++ b/plugins/mouse/mouse.c @@ -78,7 +78,8 @@ static void foreach_clear(GQuark key, gpointer data, gpointer user_data) MouseBinding *b = it->data; for (i = 0; i < NUM_MOUSEACTION; ++i) - action_free(b->action[i]); + if (b->action[i] != NULL) + action_free(b->action[i]); g_free(b); } g_slist_free(data); @@ -328,8 +329,7 @@ static gboolean mbind(char *buttonstr, char *contextstr, MouseAction mact, b->state = state; b->button = button; for (i = 0; i < NUM_MOUSEACTION; ++i) - if (i != mact) - b->action[i] = NULL; + b->action[i] = NULL; b->action[mact] = action; g_datalist_id_set_data(&bound_contexts, context, g_slist_append(g_datalist_id_get_data(&bound_contexts, context), b)); |
