That takes care of the error about assigning to a constant (oops), but still
prints the exception to the console.

Regards,
  JJ

--
Be Kind, Be Careful, Be Yourself
--
Solid, reliable software at reasonable prices
http://www.johnjohnsonsoftware.com


"Jim Menard" <jimm / eris.io.com> wrote in message
news:wsqzoc3j63j.fsf / eris.io.com...
> "J J" <jj5412 / earthlink.net> writes:
>
> > How about:
> >
> > nulFile = File.open('nul', 'w')      # UNIX: nulFile =
> > File.open('/dev/null', 'w')
> > STDERR = nulFile
> >
> > etc.
> >
> > Trouble is, exceptions don't seem to print to STDERR, or STDOUT.
>
> Untested answer: try assigning to $stderr and $stdout (global variables)
> instead of STERR and STDOUT (constants containing the default values of
> $stderr and $stdout).
>
> Jim
> --
> Jim Menard, jimm / io.com, http://www.io.com/~jimm/
> "Even anarchists have an agenda." -- Keith Beal
>