[mirrorbrain-commits] r8155 - /trunk/mod_mirrorbrain/mod_mirrorbrain.c

From: <poeml_at_mirrorbrain.org>
Date: Fri, 24 Sep 2010 14:59:45 -0000
Author: poeml
Date: Fri Sep 24 16:59:43 2010
New Revision: 8155

URL: http://svn.mirrorbrain.org/viewvc/mirrorbrain?rev=8155&view=rev
Log:
Under the conditions that 
 - an Accept is sent with "application/metalink+xml" or "metalink4+xml", 
 - and the request goes to a path that doesn't exist, 
 - but when an extension (.foo) is split off, 
 - and a corresponding path exists,
mod_mirrorbrain delivered the file matching the path with the extension split off, 
instead of replying with a 404 Not found. Fixing issue #75, which was found and
fixed by Michael Schroeder.

Modified:
    trunk/mod_mirrorbrain/mod_mirrorbrain.c

Modified: trunk/mod_mirrorbrain/mod_mirrorbrain.c
URL: http://svn.mirrorbrain.org/viewvc/mirrorbrain/trunk/mod_mirrorbrain/mod_mirrorbrain.c?rev=8155&r1=8154&r2=8155&view=diff
==============================================================================
--- trunk/mod_mirrorbrain/mod_mirrorbrain.c (original)
+++ trunk/mod_mirrorbrain/mod_mirrorbrain.c Fri Sep 24 16:59:43 2010
_at_@ -1304,6 +1304,7 @@
                 return DECLINED;
             } 
 
+            rep = UNKNOWN;
             for (i = 0; reps[i].ext; i++) {
                 if (strcmp(ext + 1, reps[i].ext) == 0) {
                     rep = i;




_______________________________________________
mirrorbrain-commits mailing list
Archive: http://mirrorbrain.org/archive/mirrorbrain-commits/

Note: To remove yourself from this list, send a mail with the content
 	unsubscribe
to the address mirrorbrain-commits-request_at_mirrorbrain.org
Received on Fri Sep 24 2010 - 14:59:48 GMT

This archive was generated by hypermail 2.3.0 : Mon Feb 20 2012 - 23:47:04 GMT