Tim_Brown
Feb 17, 2006Nimbostratus
regsub failing
I used bl0ndie's search and replace code, the short version:
when HTTP_REQUEST {
HTTP::version 1.0
}
when HTTP_RESPONSE {
HTTP::collect 4294967295
}
when HTTP_RESPONSE_DATA {
set find ":8088"
set replace ""
set payload [HTTP::payload]
if {[regsub -all $find $payload $replace new_response] > 0} {
HTTP::payload replace 0 [HTTP::payload len] $new_response
}
}
to attempt to search and replace ":8088" with "" (nothing). I've gone so far as to log the HTTP::payload after the "set payload" line and the string I'm searching for is there, but it appears as though the regsub evaluation is failing as the response never gets rewritten.
Any help here would be appreciated.