dovecot-2.2: lib-http: http_url_parse() didn't allocate all stri...
dovecot at dovecot.org
dovecot at dovecot.org
Thu Nov 29 02:02:19 EET 2012
details: http://hg.dovecot.org/dovecot-2.2/rev/12a31e13fcab
changeset: 15432:12a31e13fcab
user: Timo Sirainen <tss at iki.fi>
date: Thu Nov 29 02:01:56 2012 +0200
description:
lib-http: http_url_parse() didn't allocate all strings from the given pool.
diffstat:
src/lib-http/http-url.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (24 lines):
diff -r c9f6deb65d7b -r 12a31e13fcab src/lib-http/http-url.c
--- a/src/lib-http/http-url.c Thu Nov 29 01:57:40 2012 +0200
+++ b/src/lib-http/http-url.c Thu Nov 29 02:01:56 2012 +0200
@@ -94,7 +94,7 @@
}
if (ret > 0 && url != NULL) {
- url->host_name = auth.host_literal;
+ url->host_name = p_strdup(parser->pool, auth.host_literal);
url->host_ip = auth.host_ip;
url->have_host_ip = auth.have_host_ip;
url->port = auth.port;
@@ -166,9 +166,9 @@
}
if (url != NULL)
- url->path = str_c(fullpath);
+ url->path = p_strdup(parser->pool, str_c(fullpath));
} else if (relative && url != NULL) {
- url->path = base->path;
+ url->path = p_strdup(parser->pool, base->path);
}
/* [ "?" query ] */
More information about the dovecot-cvs
mailing list