diff options
author | Andrew Bartlett <abartlet@samba.org> | 2008-08-21 12:51:06 +1000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2008-08-21 12:51:06 +1000 |
commit | 4016cfcab7bfb3ffd48a7592fa16952688525493 (patch) | |
tree | 3f739ea23dec5a4ba605f3ac8681a24567e6e3d5 /source4/lib | |
parent | c06e928580702f1290eb475f71932b2c550ad7ff (diff) | |
download | samba-4016cfcab7bfb3ffd48a7592fa16952688525493.tar.gz samba-4016cfcab7bfb3ffd48a7592fa16952688525493.tar.bz2 samba-4016cfcab7bfb3ffd48a7592fa16952688525493.zip |
Don't allow a NULL syntax
(This used to be commit 505a0c2b702b696b91dab683626bb25b14a49c38)
Diffstat (limited to 'source4/lib')
-rw-r--r-- | source4/lib/ldb/common/ldb_attributes.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source4/lib/ldb/common/ldb_attributes.c b/source4/lib/ldb/common/ldb_attributes.c index 3b9d01682c..747f241781 100644 --- a/source4/lib/ldb/common/ldb_attributes.c +++ b/source4/lib/ldb/common/ldb_attributes.c @@ -51,6 +51,10 @@ int ldb_schema_attribute_add_with_syntax(struct ldb_context *ldb, int i, n; struct ldb_schema_attribute *a; + if (!syntax) { + return LDB_ERR_OPERATIONS_ERROR; + } + n = ldb->schema.num_attributes + 1; a = talloc_realloc(ldb, ldb->schema.attributes, |