[EMAIL PROTECTED] wrote: > -static int xbithack_handler(request_rec *r) > +static int include_fixup(request_rec *r) > { > #if defined(OS2) || defined(WIN32) || defined(NETWARE) > /* OS/2 dosen't currently support the xbithack. This is being worked on. */ > @@ -3201,17 +3201,28 @@ > conf = (include_dir_config *) ap_get_module_config(r->per_dir_config, > &include_module); > > - if (*conf->xbithack == xbithack_off) { > - return DECLINED; > + if (r->handler && (strcmp(r->handler, "server-parsed") == 0)) > + { > + if (!r->content_type || !*r->content_type) { > + r->content_type = "text/html"; > + } > + r->handler = "default-handler"; > } > + else > + { > + if (strcmp(r->handler, "text/html")) { > + return DECLINED; > + } > + > + if (*conf->xbithack == xbithack_off) { > + return DECLINED; > + } >
I see three problems here: * On OS/2, Win32, and Netware, you're skipping the check for handler=="server-parsed". Is that intentional? * In the 'strcmp(r->handler, "text/html")' expression, there's no guarantee that r->handler!=NULL * That same comparison should happen after, not before, the cheaper *conf->xbithack check --Brian