From: Martin Mares Date: Fri, 25 Jul 2014 10:38:18 +0000 (+0200) Subject: Extended types: Parsing of xt_str now copies the string X-Git-Tag: v6.1~3^2~49 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=b98f24d11ba97582b16d8a4d547205fe10e5ffcc;p=libucw.git Extended types: Parsing of xt_str now copies the string --- diff --git a/ucw/xtypes-basic.c b/ucw/xtypes-basic.c index 25d9fa84..2abc3acc 100644 --- a/ucw/xtypes-basic.c +++ b/ucw/xtypes-basic.c @@ -160,9 +160,9 @@ static const char *xt_str_format(void *src, u32 fmt UNUSED, struct mempool *pool return mp_strdup(pool, *((const char **) src)); } -static const char *xt_str_parse(const char *str, void *dest, struct mempool *pool UNUSED) +static const char *xt_str_parse(const char *str, void *dest, struct mempool *pool) { - *((const char **) dest) = str; + *((const char **) dest) = mp_strdup(pool, str); return NULL; }