Merge pull request #571 from g3offrey/master

html_encode the + character
This commit is contained in:
van Hauser 2020-10-16 16:24:46 +02:00 committed by GitHub
commit 927ed229f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -582,6 +582,8 @@ char *html_encode(char *string) {
ret = hydra_strrep(ret, "#", "%23"); ret = hydra_strrep(ret, "#", "%23");
if (index(ret, '=') != NULL) if (index(ret, '=') != NULL)
ret = hydra_strrep(ret, "=", "%3D"); ret = hydra_strrep(ret, "=", "%3D");
if (index(ret, '+') != NULL)
ret = hydra_strrep(ret, "+", "%2B");
return ret; return ret;
} }