summaryrefslogtreecommitdiffstats
path: root/source3/lib/ldb
diff options
context:
space:
mode:
authorVolker Lendecke <vlendec@samba.org>2006-10-04 20:59:06 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:15:09 -0500
commit407873df53db6fb7302ffda53de214e64cd75a09 (patch)
treed806feb7875900fa8a699064717edbcc329299e1 /source3/lib/ldb
parent8f553d8d3cbdf372ddbcbdaab48ef16296d3872c (diff)
downloadsamba-407873df53db6fb7302ffda53de214e64cd75a09.tar.gz
samba-407873df53db6fb7302ffda53de214e64cd75a09.tar.xz
samba-407873df53db6fb7302ffda53de214e64cd75a09.zip
r19079: talloc_array can fail
(This used to be commit 7b6738522a80740824f3b96e73e7c48a0623b1b1)
Diffstat (limited to 'source3/lib/ldb')
-rw-r--r--source3/lib/ldb/common/ldb_dn.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/source3/lib/ldb/common/ldb_dn.c b/source3/lib/ldb/common/ldb_dn.c
index f1d0f185ad1..f9b044d5b84 100644
--- a/source3/lib/ldb/common/ldb_dn.c
+++ b/source3/lib/ldb/common/ldb_dn.c
@@ -698,6 +698,7 @@ struct ldb_dn *ldb_dn_copy_partial(void *mem_ctx, const struct ldb_dn *dn, int n
newdn->comp_num = num_el;
n = newdn->comp_num - 1;
newdn->components = talloc_array(newdn, struct ldb_dn_component, newdn->comp_num);
+ if (newdn->components == NULL) goto failed;
if (dn->comp_num == 0) return newdn;
e = dn->comp_num - 1;