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:
60ec0f1
)
s4:torture Silence const warning by use of data_blob_const()
author
Andrew Bartlett
<abartlet@samba.org>
Wed, 21 Oct 2009 23:17:35 +0000
(10:17 +1100)
committer
Andrew Bartlett
<abartlet@samba.org>
Wed, 21 Oct 2009 23:17:35 +0000
(10:17 +1100)
This was inspired by one of mdw's const patches
Andrew Bartlett
source4/torture/ldb/ldb.c
patch
|
blob
|
history
diff --git
a/source4/torture/ldb/ldb.c
b/source4/torture/ldb/ldb.c
index 23c9bb23331942d0e5636fde1680207b50411e07..f986372fe94fe818cdb02a1c8736147a884be260 100644
(file)
--- a/
source4/torture/ldb/ldb.c
+++ b/
source4/torture/ldb/ldb.c
@@
-665,8
+665,7
@@
static bool torture_ldb_dn(struct torture_context *torture)
ldb_dn_validate(dn) == false,
"should have failed to validate a DN with 0xA in it");
- val.data = "CN=Zer\0,DC=SAMBA,DC=org";
- val.length = 23;
+ val = data_blob_const("CN=Zer\0,DC=SAMBA,DC=org", 23);
torture_assert(torture,
NULL == ldb_dn_from_ldb_val(mem_ctx, ldb, &val),
"should fail to create a DN with 0x0 in it");