summaryrefslogtreecommitdiff
path: root/lwlib/lwlib.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2008-06-02 06:00:54 +0000
committerJim Meyering <jim@meyering.net>2008-06-02 06:00:54 +0000
commitc2cd06e61e6f21eeb1077b557a22cc5aaf795676 (patch)
treeec7d44c58c8b7f4a84065a04163351dc9c96f552 /lwlib/lwlib.c
parent437eedba09d67a807d2547886bd3e8fae81138a3 (diff)
remove useless if-before-free tests
* lib-src/ebrowse.c (xfree): Likewise. * lib-src/etags.c (process_file_name, free_tree, free_fdesc): Likewise. (popclass_above, Prolog_functions, Erlang_functions): Likewise. * lib-src/pop.c (pop_quit): Likewise. * lwlib/lwlib-Xm.c (xm_update_one_value): Likewise. * lwlib/lwlib.c (safe_free_str, free_widget_value_tree): Likewise. * src/editfns.c (Fset_time_zone_rule): Likewise. * src/lread.c (nosuffix): Likewise. * src/ralloc.c (get_bloc): Likewise. * src/regex.c (reg_free): Likewise. * src/xftfont.c (xftfont_open, xftfont_close): Likewise. * src/xrdb.c (get_user_app, get_environ_db, x_load_resources): Likewise. * src/xsmfns.c (smc_save_yourself_CB): Likewise.
Diffstat (limited to 'lwlib/lwlib.c')
-rw-r--r--lwlib/lwlib.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lwlib/lwlib.c b/lwlib/lwlib.c
index 7b2752b82e..03c402163e 100644
--- a/lwlib/lwlib.c
+++ b/lwlib/lwlib.c
@@ -170,7 +170,7 @@ static void
safe_free_str (s)
char *s;
{
- if (s) free (s);
+ free (s);
}
static widget_value *widget_value_free_list = 0;
@@ -226,9 +226,9 @@ free_widget_value_tree (wv)
if (!wv)
return;
- if (wv->name) free (wv->name);
- if (wv->value) free (wv->value);
- if (wv->key) free (wv->key);
+ free (wv->name);
+ free (wv->value);
+ free (wv->key);
wv->name = wv->value = wv->key = (char *) 0xDEADBEEF;