aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--e-util/ChangeLog6
-rw-r--r--e-util/e-sexp.c4
2 files changed, 10 insertions, 0 deletions
diff --git a/e-util/ChangeLog b/e-util/ChangeLog
index fd727c9505..9458c4fdc3 100644
--- a/e-util/ChangeLog
+++ b/e-util/ChangeLog
@@ -1,3 +1,9 @@
+2003-04-15 Hans Petter Jansson <hpj@ximian.com>
+
+ * e-sexp.c (e_sexp_add_function)
+ (e_sexp_add_ifunction): Make sure any old symbol with the same name
+ as the one being added, is removed first.
+
2003-04-14 Not Zed <NotZed@Ximian.com>
* e-gtk-utils.c (e_gtk_button_new_with_icon): Utility function to
diff --git a/e-util/e-sexp.c b/e-util/e-sexp.c
index f21c6dacd3..a9b46e440f 100644
--- a/e-util/e-sexp.c
+++ b/e-util/e-sexp.c
@@ -1181,6 +1181,8 @@ e_sexp_add_function(ESExp *f, int scope, char *name, ESExpFunc *func, void *data
g_return_if_fail (IS_E_SEXP (f));
g_return_if_fail (name != NULL);
+ e_sexp_remove_symbol (f, scope, name);
+
s = g_malloc0(sizeof(*s));
s->name = g_strdup(name);
s->f.func = func;
@@ -1197,6 +1199,8 @@ e_sexp_add_ifunction(ESExp *f, int scope, char *name, ESExpIFunc *ifunc, void *d
g_return_if_fail (IS_E_SEXP (f));
g_return_if_fail (name != NULL);
+ e_sexp_remove_symbol (f, scope, name);
+
s = g_malloc0(sizeof(*s));
s->name = g_strdup(name);
s->f.ifunc = ifunc;