running code after FCGX_Accept fails

"alexander johnson" <[email protected]>
Newsgroups gmane.comp.web.fastcgi.devel,gmane.spam.detected
Message-ID <[email protected]>
Hi,
There some very important cleanup code i need to run after FCGX_Accept
== -1 and exits its loop.  The problem is that the program exits
immediately after FCGX_Accept == -1 so  cant run any code after.  I've
tied arranging my code in various ways to get it to run this code but
im having no luck. A sample is below, im using c++ btw, any
suggestions?

example 1

bool finish = false;

while(finish == false)
{
    if(FCGX_Accept( &in, &out, &err, &envp ) ==-1){
     cleanup();//important code i need to run on exit
     finish = true;
    }
else
    {
     //code I run during normal execution

    }

}



any help would be greatly appreciated,
thanks

-- 
Alex
___________________________________
fastcgi-developers mailing list
http://fastcgi.com/fastcgi-developers/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.