diff options
author | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-09-29 15:54:32 +0000 |
---|---|---|
committer | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-09-29 15:54:32 +0000 |
commit | c73eb341d289621235f1d91b962d6f45692e1158 (patch) | |
tree | 03f94411c11d556ddf463d4b4cb27a16fcbba3a1 /ext/tcltklib/tcltklib.c | |
parent | 2589e9f012c08e9aec7202686c9e888099aa6ab5 (diff) | |
download | ruby-c73eb341d289621235f1d91b962d6f45692e1158.tar.gz ruby-c73eb341d289621235f1d91b962d6f45692e1158.tar.xz ruby-c73eb341d289621235f1d91b962d6f45692e1158.zip |
* ext/tcltklib/tcltklib.c (ip_init): bug fix
* ext/tk/tkutil.c (get_eval_string_core): accept a Regexp object
* ext/tk/lib/multi-tk.rb: fix bug on 'exit' operation
* ext/tk/lib/tk/text.rb: 'tksearch' accepts a Regexp object as a
matting pattern argument
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@6973 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/tcltklib/tcltklib.c')
-rw-r--r-- | ext/tcltklib/tcltklib.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/ext/tcltklib/tcltklib.c b/ext/tcltklib/tcltklib.c index f1a81c996..8b180bf49 100644 --- a/ext/tcltklib/tcltklib.c +++ b/ext/tcltklib/tcltklib.c @@ -3271,6 +3271,8 @@ delete_slaves(ip) char *slave_name; int i, len; + DUMP2("delete slaves of ip(%lx)", ip); + Tcl_Preserve(ip); if (Tcl_Eval(ip, "info slaves") == TCL_ERROR) { @@ -3339,7 +3341,10 @@ ip_free(ptr) thr_crit_bup = rb_thread_critical; rb_thread_critical = Qtrue; + DUMP2("IP ref_count = %d", ptr->ref_count); + if (!Tcl_InterpDeleted(ptr->ip)) { + DUMP2("IP(%lx) is not deleted", ptr->ip); /* Tcl_Preserve(ptr->ip); */ rbtk_preserve_ip(ptr); @@ -3369,6 +3374,7 @@ ip_free(ptr) } rbtk_release_ip(ptr); + DUMP2("IP ref_count = %d", ptr->ref_count); free(ptr); @@ -3418,7 +3424,8 @@ ip_init(argc, argv, self) rb_raise(rb_eRuntimeError, "fail to create a new Tk interpreter"); } - rbtk_preserve_ip((ClientData)ptr->ip); + rbtk_preserve_ip(ptr); + DUMP2("IP ref_count = %d", ptr->ref_count); current_interp = ptr->ip; ptr->has_orig_exit |