git.samba.org
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a26a489
)
ldb:ldbsearch.c - fix possible uninitialised variable
author
Matthias Dieter Wallnöfer
<mdw@samba.org>
Sat, 8 Jan 2011 21:08:40 +0000
(22:08 +0100)
committer
Matthias Dieter Wallnöfer
<mdw@samba.org>
Wed, 12 Jan 2011 18:52:19 +0000
(19:52 +0100)
And add a comparison for the "ret" result - this is more standard-oriented
source4/lib/ldb/tools/ldbsearch.c
patch
|
blob
|
history
diff --git
a/source4/lib/ldb/tools/ldbsearch.c
b/source4/lib/ldb/tools/ldbsearch.c
index 6059ac6c5011b27c523be38339db7f14684cc353..28ec743bcb328eeef94a405f2e288b53f7c1b96b 100644
(file)
--- a/
source4/lib/ldb/tools/ldbsearch.c
+++ b/
source4/lib/ldb/tools/ldbsearch.c
@@
-133,7
+133,7
@@
static int display_referral(char *referral, struct search_context *sctx)
static int search_callback(struct ldb_request *req, struct ldb_reply *ares)
{
struct search_context *sctx;
- int ret;
+ int ret
= LDB_SUCCESS
;
sctx = talloc_get_type(req->context, struct search_context);
@@
-174,7
+174,7
@@
static int search_callback(struct ldb_request *req, struct ldb_reply *ares)
}
talloc_free(ares);
- if (ret) {
+ if (ret
!= LDB_SUCCESS
) {
return ldb_request_done(req, LDB_ERR_OPERATIONS_ERROR);
}