There is a small regression in v2.19 when processing base URLs. In case the value in the "href" attribute of a base element starts with whitespace, the resulting base URL is wrong. See below what happens:
URL of main page:
"http://localhost/index.html"
Value of the href attribute of the page's base element:
" http://localhost/"
Expected base URL:
"http://localhost/"
Actual base URL:
"http://localhost/index.html http://localhost/"
Looks like the code doesn't recognize the specified base URL as absolute URL because of the leading whitespace and constructs a base URL from the page's URL.
Attached is a patch that adds another test to HtmlPage3Test and tries to fix this issue.
As always thanks for the patch.