On 23/12/2010 10:58, Eugaia wrote:
> Hi,
>
> On 23/12/2010 04:50, Sirsiwal, Umesh wrote:
>> I just tried using error_pages and have my post_subrequest return the
>> error code as Maxim had suggested.
>>
>> That works very well. The only oddity is that I get two
>> post_subrequest callback for a single subrequest. That is something I
>> can handle my module.
> Good. In your post_subrequest function, assuming you only want it
> called once, you should set sr->post_subrequest = NULL.
Or test to see if you've already run the post_subrequest by creating a
context struct and a flag to say whether you've called the function
before (but personally I prefer the former because then you don't end up
calling the same function loads of times unnecessarily).
> Marcus.
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://nginx.org/mailman/listinfo/nginx-devel