My suspicion is that the CLEANUP routine is called after the response to the client is put into the output buffer, but before the output buffer is flushed. As redirects are always fairly short, the redirect fits entirely within one buffer in this case, and so nothing has been sent to the client yet, even though all other processing has finished.
I'm using Embperl 1.3.4, so I can't say for certain this is what is happening, but I do notice something similar on pages that have an extended cleanup process - the tail of the page doesn't show up until that process finishes. I haven't complained about this, as this condition only occurs on some of my test pages. Ed On Thu, 8 Jul 2004, Katherine Spice wrote: > Hi, > > I have an embperl page that does some stuff, and then spits out a > redirect using $http_headers_out{'Location'}. From > http://perl.apache.org/embperl/pod/doc/Embperl.-page-4-.htm it was my > understanding that any code I defined in a CLEANUP subroutine would be > run after the response was sent to the client, however when I've tested > it by putting in the page [! sub CLEANUP { sleep 15; } !] the redirect > isn't issued for 15 seconds. Please would somebody take pity on me and > explain what I'm missing? > > Thanks, > Katherine > > FWIW I'm using Embperl 2.0b9, with Embperl::Object as the PerlHandler on > Apache 1.3.27 with mod_perl 1.26. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]