From: Patrick Joyce Date: 2007-11-02T04:07:24+09:00 Subject: Re: Apache mod_rewrite External Rewriting Program OK, so I'm now actually pretty sure this isn't a problem with my Ruby code, but a problem with either Solaris or Apache. I went ahead and took the Perl example from the Apache docs, modified it slightly to match my example, and still got the same problem: intermittently interleaved results. This makes me pretty confident that the problem is outside of Ruby (unless of course, and I'm not ruling this out, I somehow made the same mistake in both Ruby and Perl). Since it doesn't seem to be a Ruby issue I don't expect any help here, but if anyone has ANY idea what could be going on I would be forever in your debt. - Patrick Joyce The Perl is below. ----------------- #!/usr/bin/perl #disable buffered I/O which would lead #to deadloops for the Apache serve $| = 1; #read URLs one per line from stdin and #generate substitution URL on stdout while (<>) { /^(.+)\.somedomain\.com$/; print $1, "\n"; } ----------------- -- Posted via http://www.ruby-forum.com/.