1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-21 18:04:06 +03:00

ctdb-conn: add missing variable initialization

Avoid potential crash in TALLOC_FREE(hdr).

Signed-off-by: Ralph Wuerthner <ralph.wuerthner@de.ibm.com>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
(cherry picked from commit 4194c0797f78293fe48105ce5af70f36a3c233a8)

BUG: https://bugzilla.samba.org/show_bug.cgi?id=12372
ctdb: bad free in ctdbd_migrate()
This commit is contained in:
Ralph Wuerthner 2016-10-10 16:26:05 +02:00 committed by Karolin Seeger
parent ac341c7e01
commit bb8e4c78e8

View File

@ -919,7 +919,7 @@ int ctdbd_db_attach(struct ctdbd_connection *conn,
int ctdbd_migrate(struct ctdbd_connection *conn, uint32_t db_id, TDB_DATA key) int ctdbd_migrate(struct ctdbd_connection *conn, uint32_t db_id, TDB_DATA key)
{ {
struct ctdb_req_call_old req; struct ctdb_req_call_old req;
struct ctdb_req_header *hdr; struct ctdb_req_header *hdr = NULL;
struct iovec iov[2]; struct iovec iov[2];
ssize_t nwritten; ssize_t nwritten;
int ret; int ret;