Alright, thanks to all of you for all the good feedback. I found the error.log file and will keep an eye on it. My current solution is a combination of passing arguments to the subroutine and using variables scoped with our instead of my. I'll keep fooling around with this issue until I understand enough about these different options to make a determination as to which is preferable.
Thanks again to all of you.