git.samba.org
/
ira
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
91febc3
)
Added talloc_strdup() funcion.
author
Tim Potter
<tpot@samba.org>
Fri, 11 May 2001 07:03:13 +0000
(07:03 +0000)
committer
Tim Potter
<tpot@samba.org>
Fri, 11 May 2001 07:03:13 +0000
(07:03 +0000)
(This used to be commit
eea43a5a916eb7f4bef6817ce0aa8051f9145b18
)
source3/lib/talloc.c
patch
|
blob
|
history
diff --git
a/source3/lib/talloc.c
b/source3/lib/talloc.c
index 860fc67bcbb4f1f957f60e6ba928c012b4e9ab28..4c263ec4d6189f1d733f81c3f82d16c121aa53b5 100644
(file)
--- a/
source3/lib/talloc.c
+++ b/
source3/lib/talloc.c
@@
-158,3
+158,9
@@
void *talloc_memdup(TALLOC_CTX *t, void *p, size_t size)
return newp;
}
+
+/* strdup with a talloc */
+char *talloc_strdup(TALLOC_CTX *t, char *p)
+{
+ return talloc_memdup(t, p, strlen(p) + 1);
+}