Toby Thain wrote:




Begin forwarded message:


    *From: *Gilles Detillieux <[EMAIL PROTECTED]>
    *Date: *31 March 2004 4:12:58 AM
    *To: [EMAIL PROTECTED] (Toby Thain)
    *Cc: [EMAIL PROTECTED] (David Adams),
    [EMAIL PROTECTED] (ht://Dig mailing list)
    *Subject: Re: [htdig] query parameters should be ignored by
    extension filter? - PATCH for 3.1.6
    *
    Last week, I wrote:

[...]


OK, last week got a bit crazy, so I wrote the patch yesterday afternoon, just before the end of my work day. Here it is. Apply it in your main 3.1.6 source directory using "patch -p0 < this-message-file". Please let me know if it solves the problem for you and/or causes others. I've made sure the code compiles with the patch, but haven't tested it beyond that. Thanks.


Gilles,

Great work, I have installed the patch to my two 3.1.6 installations
(development and deployment) and it works perfectly now.
Thankyou!

Toby


--- htdig/Retriever.cc.orig 2002-01-25 07:44:49.000000000 -0600 +++ htdig/Retriever.cc 2004-03-29 17:40:07.000000000 -0600 @@ -711,16 +711,17 @@ Retriever::IsValidURL(char *u) // // See if the path extension is in the list of invalid ones // - char *ext = strrchr(url, '.'); + String urlpath = url.get(); + int parm = urlpath.indexOf('?'); // chop off URL parameter + if (parm >= 0) + urlpath.chop(urlpath.length() - parm); + char *ext = strrchr(urlpath, '.'); String lowerext; if (ext && strchr(ext, '/')) // Ignore a dot if it's not in the ext = NULL; // final component of the path. if (ext) { lowerext = ext; - int parm = lowerext.indexOf('?'); // chop off URL parameter - if (parm >= 0) - lowerext.chop(lowerext.length() - parm); lowerext.lowercase(); if (invalids->Exists(lowerext)) {

-- Gilles R. Detillieux E-mail: <[EMAIL PROTECTED]>
Spinal Cord Research Centre WWW: http://www.scrc.umanitoba.ca/
Dept. Physiology, U. of Manitoba Winnipeg, MB R3E 3J7 (Canada)










-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
ht://Dig general mailing list: <[EMAIL PROTECTED]>
ht://Dig FAQ: http://htdig.sourceforge.net/FAQ.html
List information (subscribe/unsubscribe, etc.)
https://lists.sourceforge.net/lists/listinfo/htdig-general

Reply via email to