aurelianito wrote: > I want to say things like evil.rb code can write to "evil.log" but to > nothing else. > How can use threads to say this kind of things with threads? > require 'thread' write_queue = Queue.new safe_thread = Thread.new do $SAFE = 4 data = "some data" write_queue << data end write_thread = Thread.new do loop do data = write_queue.pop puts data # or write to "evil.log" end end sleep 0.1 -- vjoel : Joel VanderWerf : path berkeley edu : 510 665 3407