in reply to Bad file descriptor when trying to close file handle

my guess are scoping problems, since there is no my $fh_debug

do you use strict and warnings ?

> P.S. How can I prevent the lines between my < code > and < /code > tags from wrapping prematurely?

you don't. The wrapping depends on the Display Settings of the users reading it.

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery