summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/gns/gnunet-service-gns_resolver.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gns/gnunet-service-gns_resolver.c b/src/gns/gnunet-service-gns_resolver.c
index 41c2c0de0..d79817293 100644
--- a/src/gns/gnunet-service-gns_resolver.c
+++ b/src/gns/gnunet-service-gns_resolver.c
@@ -93,7 +93,9 @@ process_pseu_lookup_ns(void* cls,
GNUNET_log(GNUNET_ERROR_TYPE_DEBUG,
"Trying delegated name %s\n", gph->name);
- gph->new_name = gph->name;
+ GNUNET_free(gph->new_name);
+ gph->new_name = GNUNET_malloc(strlen(gph->name)+1);
+ memcpy(gph->new_name, gph->name, strlen(gph->name)+1);
GNUNET_NAMESTORE_lookup_record(namestore_handle,
&gph->zone,
gph->new_name,