From new-httpd-owner@apache.org Sat Feb 1 14:54:09 1997 Received: by taz.hyperreal.com (8.8.4/V2.0) id OAA06694; Sat, 1 Feb 1997 14:54:09 -0800 (PST) Received: from twinlark.arctic.org by taz.hyperreal.com (8.8.4/V2.0) with SMTP id OAA06690; Sat, 1 Feb 1997 14:54:06 -0800 (PST) Received: (qmail 2612 invoked by uid 500); 1 Feb 1997 22:54:11 -0000 Date: Sat, 1 Feb 1997 14:54:11 -0800 (PST) From: Dean Gaudet To: new-httpd@apache.org cc: Markus Gyger Subject: PR#77 issue 301 for "foo -> foo/" directory redirects Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: new-httpd-owner@apache.org Precedence: bulk Reply-To: new-httpd@hyperreal.com Submitted by: Markus Gyger Issue a 301 response instead of a 302 response when returning a directory redirect for "/foo" to "/foo/". This allows the redirect to be cached. Nothing in rfc2068 would lead me to belive this is a bad idea. But one problem that might occur is the inability to change "/foo" to a file or other resource instead of a directory without caching problems. But this is true of a bunch of things... Navigator seems to only cache the redirect in memory not on disk. Netscape-Enterprise/2.01, and CERN/3.0A issue 302s just like Apache presently does. I'm all for improving cacheability. Dean Index: mod_dir.c =================================================================== RCS file: /export/home/cvs/apache/src/mod_dir.c,v retrieving revision 1.20 diff -c -3 -r1.20 mod_dir.c *** mod_dir.c 1997/01/12 20:11:53 1.20 --- mod_dir.c 1997/02/01 22:33:23 *************** *** 784,790 **** table_set (r->headers_out, "Location", construct_url(r->pool, ifile, r->server)); ! return REDIRECT; } /* KLUDGE --- make the sub_req lookups happen in the right directory. --- 784,790 ---- table_set (r->headers_out, "Location", construct_url(r->pool, ifile, r->server)); ! return MOVED; } /* KLUDGE --- make the sub_req lookups happen in the right directory.