summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@sernet.de>2008-01-30 10:34:57 +0100
committerStefan Metzmacher <metze@samba.org>2009-01-19 07:05:21 +0100
commit996790719066d92f563bf53fe4222d2b5e3863a5 (patch)
tree6c679b901d826c2b0894b8a4df141f2ea0fd3bc0
parent9d4f766ae35176b0597dd359d692e4166c2314fc (diff)
downloadsamba-996790719066d92f563bf53fe4222d2b5e3863a5.tar.gz
samba-996790719066d92f563bf53fe4222d2b5e3863a5.tar.bz2
samba-996790719066d92f563bf53fe4222d2b5e3863a5.zip
util_str: setup the correct talloc name for strings
metze (partly from samba4wins tree 447e7f9532131117e896712db9def321c96718eb)
-rw-r--r--lib/util/substitute.c2
-rw-r--r--lib/util/util_str.c2
-rw-r--r--source4/libcli/raw/rawfile.c2
3 files changed, 6 insertions, 0 deletions
diff --git a/lib/util/substitute.c b/lib/util/substitute.c
index 84514ac714..32945a7213 100644
--- a/lib/util/substitute.c
+++ b/lib/util/substitute.c
@@ -120,6 +120,8 @@ _PUBLIC_ char *string_sub_talloc(TALLOC_CTX *mem_ctx, const char *s,
SMB_ASSERT(ret[len] == '\0');
+ talloc_set_name_const(ret, ret);
+
return ret;
}
diff --git a/lib/util/util_str.c b/lib/util/util_str.c
index 7dcefc90dd..a2c50fd38f 100644
--- a/lib/util/util_str.c
+++ b/lib/util/util_str.c
@@ -153,6 +153,8 @@ _PUBLIC_ const char *str_format_nbt_domain(TALLOC_CTX *mem_ctx, const char *s)
}
}
+ talloc_set_name_const(ret, ret);
+
return ret;
}
diff --git a/source4/libcli/raw/rawfile.c b/source4/libcli/raw/rawfile.c
index 8cabac6d04..63de051b33 100644
--- a/source4/libcli/raw/rawfile.c
+++ b/source4/libcli/raw/rawfile.c
@@ -71,6 +71,8 @@ char *attrib_string(TALLOC_CTX *mem_ctx, uint32_t attrib)
ret[len] = 0;
+ talloc_set_name_const(ret, ret);
+
return ret;
}