From: Patrik Sundberg Date: 2002-04-03T00:41:12+09:00 Subject: metaruby mainloop I am trying to use MetaRuby's MainLoop class in an application of mine and are having some trouble with timers. I think I found a bug here: def delay_until_next return delay_no_next if @queue.length == 0 delay = @queue[0].time - Time.new delay = 0 if delay < 0 end which should be: def delay_until_next return delay_no_next if @queue.length == 0 delay = @queue[0].time - Time.new delay = 0 if delay < 0 return delay end Otherwise this function will return nil and the select in the loop later on will hang forever (if you're not using any streams). Have I misunderstod something or is it a bug? -- ---------------------------------------------------------------------------. Patrik Sundberg Address: Rydsv�gen 100C, 584 31 Link�ping, Sweden | Email: ps@raditex.se || ps@radiac.mine.nu | Phone: +46 13 178567 || +46 707 602240 | .---> Applied Physics and Electrical Engineering student | |-----> Master of Science in Business Administration and Economics student | |-------> UNIX/Programming consultant | `--------------------------------------------------------------------------'