aboutsummaryrefslogtreecommitdiff
path: root/jim.c
diff options
context:
space:
mode:
authorantirez <antirez>2005-03-11 09:31:36 +0000
committerantirez <antirez>2005-03-11 09:31:36 +0000
commitdd812eddd8b4d4e14ac4f34724e97afff880f7c3 (patch)
treefe2d35520b9f990fdd34a90a8eb28d17b06218d2 /jim.c
parent82a9d97a1dc4f107d23ce03bd6b2ca358d7a09c3 (diff)
downloadjimtcl-dd812eddd8b4d4e14ac4f34724e97afff880f7c3.zip
jimtcl-dd812eddd8b4d4e14ac4f34724e97afff880f7c3.tar.gz
jimtcl-dd812eddd8b4d4e14ac4f34724e97afff880f7c3.tar.bz2
Fix about [rename] against procedures with statics.
Added a regression test to test.tcl (I plan to move everything inside regtest.tcl into test.tcl).
Diffstat (limited to 'jim.c')
-rw-r--r--jim.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/jim.c b/jim.c
index de2c9b3..a0ae727 100644
--- a/jim.c
+++ b/jim.c
@@ -1,7 +1,7 @@
/* Jim - A small embeddable Tcl interpreter
* Copyright 2005 Salvatore Sanfilippo <antirez@invece.org>
*
- * $Id: jim.c,v 1.90 2005/03/11 09:25:45 antirez Exp $
+ * $Id: jim.c,v 1.91 2005/03/11 09:31:36 antirez Exp $
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -2859,6 +2859,8 @@ int Jim_RenameCommand(Jim_Interp *interp, const char *oldName,
* freed by the hash table methods, fake a C-coded command
* setting cmdPtr->cmdProc as not NULL */
cmdPtr->cmdProc = (void*)1;
+ /* Also make sure delProc is NULL. */
+ cmdPtr->delProc = NULL;
/* Destroy the old command, and make sure the new is freed
* as well. */
Jim_DeleteHashEntry(&interp->commands, oldName);