commit d9e35ca: [Minor] Add trailing slash when reconstructing numeric url
Vsevolod Stakhov
vsevolod at highsecure.ru
Sat Jan 11 13:42:06 UTC 2020
Author: Vsevolod Stakhov
Date: 2020-01-11 13:38:26 +0000
URL: https://github.com/rspamd/rspamd/commit/d9e35ca50f4cf853fb2a2a4505cccbd1a761cfce (HEAD -> master)
[Minor] Add trailing slash when reconstructing numeric url
---
src/libserver/url.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/libserver/url.c b/src/libserver/url.c
index bb32063d7..cb9c214d2 100644
--- a/src/libserver/url.c
+++ b/src/libserver/url.c
@@ -1602,6 +1602,11 @@ rspamd_url_regen_from_inet_addr (struct rspamd_url *uri, const void *addr, int a
uri->data);
uri->data = p;
}
+ else {
+ /* Add trailing slash if needed */
+ r += rspamd_snprintf (strbuf + r, slen - r, "/");
+ }
+
if (uri->querylen > 0) {
p = strbuf + r + 1;
r += rspamd_snprintf (strbuf + r, slen - r, "?%*s",
More information about the Commits
mailing list