in reply to Problem with for in CGI

One reason for programs to mystically stop working when run in a different user context (CGI user versus yourself in this case), is that the OS imposes some kind of limit (CPU time or wallclock time in this case, most likely) on processes owned by said user.

That said, it would help very much, as PodMaster indicated, to reopen STDERR somewhere useful so you might actually get a helpful message.

CU
Robartes-