Hi, In message <_A3891@delegate-en.ML_> on 11/07/07(08:38:28) you "Matthias Waldorf \(Zoom\)" <pgmhqbdyi-mxhgu45vf33w.ml@delegate.org> wrote: |I'm using delegate 9.7.6 under windows as origin server for HTTP and try |to setup some special handling for 404 errors. I would like to forward |all requests where no file exists to a second server like this: | |SERVER=http | |MOUNT="/* file:///d:/www/*" |MOUNT="/* http://localhost:8001/* onerror={404}" | |However, this seem not to work. Is there any other possibility to do |this? You are right, it should work as you expect. I fixed it as the enclosed patch and uploaded the fixed version as dg9_7_7-pre1.zip to the directory of DeleGate on my FTP server. Cheers, Yutaka -- 9 9 Yutaka Sato <pfqcabdyi-mxhgu45vf33w.ml@delegate.org> http://delegate.org/y.sato/ ( ~ ) National Institute of Advanced Industrial Science and Technology _< >_ 1-1-4 Umezono, Tsukuba, Ibaraki, 305-8568 Japan Do the more with the less -- B. Fuller *** ../delegate9.7.6/src/http.c Fri Oct 26 06:42:30 2007 --- http.c Wed Nov 7 16:45:22 2007 *************** *** 4529,4534 **** --- 4529,4538 ---- if( 400 <= RX_code ){ HTTP_setRetry(Conn,req,RX_code); } + if( Conn->sv_retry & SV_RETRY_DONE ){ + /* 9.7.7 the result of a retrial */ + Verbose("-- RETRY[%X] >>> (%d)\n",Conn->sv_retry,RX_code); + }else if( Conn->sv_retry != 0 ){ sv1log("ERROR (%d) to be RETRYed\n",RX_code); RX_tcp = NULLFP(); *************** *** 9274,9279 **** --- 9278,9291 ---- if( Conn->sv_retry == SV_RETRY_DO ){ sv1log("RETRYing with [%s]...\n",REQ_URL); sprintf(REQ,"%s %s HTTP/%s\r\n",REQ_METHOD,REQ_URL,REQ_VER); + if( ToMyself || IAM_GATEWAY ){ + /* 9.7.7 error in origin/gateway-server */ + Verbose("-- ToMe:%d ImGw:%d fm=%d\n", + ToMyself,IAM_GATEWAY,Conn->from_myself); + ToMyself = 0; + IAM_GATEWAY = 0; + } + Conn->from_myself = 1; if( rewriteRequest(Conn,QX,fc,tc) < 0 ) goto EXIT; Conn->sv_retry |= SV_RETRY_DONE;