in reply to can PERL just quit?
Your code doesn't compile, because $artheader isn't defined anywhere. I saw that by putting your code in a file called test.pl and running perl -c test.pl. This checks the syntax of the program without actually running it so you can try perl -c on your file without side effects.
Edit: this means you should try and see why your tool doesn't give you any feedback on this error. The compilation error message should be sent to the standard error output, just as any error occuring during runtime.