diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2010-06-04 13:34:06 +0930 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2010-06-04 13:34:06 +0930 |
commit | 5d0d51e77b303af132e6f9f1f898f3f11f76c69a (patch) | |
tree | ff515168f8be4422ea582df66b5a6ea310098a41 /ctdb/libctdb | |
parent | c05f3ee99b7cc28a5806627cee8475dd13287b40 (diff) | |
download | samba-5d0d51e77b303af132e6f9f1f898f3f11f76c69a.tar.gz samba-5d0d51e77b303af132e6f9f1f898f3f11f76c69a.tar.xz samba-5d0d51e77b303af132e6f9f1f898f3f11f76c69a.zip |
libctdb: fix wrong argument being handed to callback on attachdb fail
When attachdb failed, we were handing the db, not the user-supplied
arg to the callback.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(This used to be ctdb commit 8626b6d7d4e5c747b6bac9d5e5b2cd302b6e144c)
Diffstat (limited to 'ctdb/libctdb')
-rw-r--r-- | ctdb/libctdb/ctdb.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ctdb/libctdb/ctdb.c b/ctdb/libctdb/ctdb.c index 8700a60dd4..43c2829c57 100644 --- a/ctdb/libctdb/ctdb.c +++ b/ctdb/libctdb/ctdb.c @@ -449,7 +449,7 @@ static void attachdb_done(struct ctdb_connection *ctdb, if (!reply || reply->status != 0) { /* We failed. Hand request to user and have them discover it * via ctdb_attachdb_recv. */ - db->callback(ctdb, req, db); + db->callback(ctdb, req, db->private_data); return; } db->id = *(uint32_t *)reply->data; @@ -460,7 +460,7 @@ static void attachdb_done(struct ctdb_connection *ctdb, &db->id, sizeof(db->id), attachdb_getdbpath_done, db); if (!req2) { - db->callback(ctdb, req, db); + db->callback(ctdb, req, db->private_data); return; } req->extra = req2; |