Fixed so it doesn't break when the HTML contains a link immediately foll...

...owing a newline

The problem was that the entire HTML source was passed in to resolve_link as base_path, even though it makes no sense.

Most of the time, however, that was okay, because it wasn't a URI nor did it match the http regexp. But, since the regexp matches ^ at each newline, if the HTML had \nhttp:// or \nftp:// or \nhttps:// anywhere in it, it would error, because it would try to URI.parse the entire HTML source.