in reply to Re: Signal handlers and scoped variables, or Nested subs?
in thread Signal handlers and scoped variables, or Nested subs?

Thank you for both of your replies.

The usage of srand was an artifact from before I put the code into sub outer. Thank you for reminding me to remove it!

I am putting the use statement inside the sub because I want to eventually make the sub into an object method. I don't want to require the main program to know that it should use IO::Socket if it wants to use this method. When I move the sub into the package file, I will remove the use statement from the sub itself and put it into the package file.

---
It's all fine and dandy until someone has to look at the code.