diff options
author | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-06-07 01:33:12 +0000 |
---|---|---|
committer | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-06-07 01:33:12 +0000 |
commit | 78e266c241447ba73e590ee1056dec3530682487 (patch) | |
tree | cd41a08887eba71cb81581e52e65ac0aa3904707 /ext/tk/lib | |
parent | 0e7ab28c36fd9524dd6d93363a1e99c270abf752 (diff) | |
download | ruby-78e266c241447ba73e590ee1056dec3530682487.tar.gz |
* ext/tk/lib/multi-tk.rb: slave-ip fails to call procedures
delegated by master-ip.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@8574 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/tk/lib')
-rw-r--r-- | ext/tk/lib/multi-tk.rb | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/ext/tk/lib/multi-tk.rb b/ext/tk/lib/multi-tk.rb index b5519af3c8..6d048e91bc 100644 --- a/ext/tk/lib/multi-tk.rb +++ b/ext/tk/lib/multi-tk.rb @@ -1333,7 +1333,7 @@ class MultiTkIp #self.eval_callback{ TkComm._get_eval_string(TkUtil.eval_cmd(cmd, *args)) } #ret = self.eval_callback{ TkComm._get_eval_string(TkUtil.eval_cmd(cmd, *args)) } ret = self.eval_callback(*args){|safe, *params| - $SAFE=safe + $SAFE=safe if $SAFE < safe TkComm._get_eval_string(TkUtil.eval_cmd(cmd, *params)) } if ret.kind_of?(Exception) @@ -1511,7 +1511,7 @@ class MultiTkIp else eval_proc_core(true, proc{|safe, *params| - $SAFE=safe + $SAFE=safe if $SAFE < safe Thread.new(*params, &cmd).value }, *args) @@ -1530,7 +1530,8 @@ class MultiTkIp Thread.new{ eval_proc_core(false, proc{|safe, *params| - $SAFE=safe; Thread.new(*params, &cmd).value + $SAFE=safe if $SAFE < safe + Thread.new(*params, &cmd).value }, *args) } @@ -1545,7 +1546,11 @@ class MultiTkIp raise RuntimeError, "A String object is expected for the 'cmd' argument" end - eval_proc_core(true, proc{|safe| $SAFE=safe; Kernel.eval(cmd, *eval_args)}) + eval_proc_core(true, + proc{|safe| + $SAFE=safe if $SAFE < safe + Kernel.eval(cmd, *eval_args) + }) end alias eval_str eval_string @@ -1556,7 +1561,10 @@ class MultiTkIp end Thread.new{ eval_proc_core(true, - proc{|safe| $SAFE=safe; Kernel.eval(cmd, *eval_args)}) + proc{|safe| + $SAFE=safe if $SAFE < safe + Kernel.eval(cmd, *eval_args) + }) } end alias background_eval_string bg_eval_string |