mirror of
https://github.com/samba-team/samba.git
synced 2025-01-06 13:18:07 +03:00
ctdbd_conn: don't use uninitialized memory in ctdbd_register_ips()
We dump the structure into the socket, so we need to zero the content
including possible padding.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=15523
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
(cherry picked from commit 240139370a
)
This commit is contained in:
parent
813e718671
commit
24d960d02b
@ -1144,6 +1144,7 @@ int ctdbd_register_ips(struct ctdbd_connection *conn,
|
||||
smbd_ctdb_canonicalize_ip(_client, &client);
|
||||
smbd_ctdb_canonicalize_ip(_server, &server);
|
||||
|
||||
ZERO_STRUCT(p);
|
||||
switch (client.ss_family) {
|
||||
case AF_INET:
|
||||
memcpy(&p.dst.ip, &server, sizeof(p.dst.ip));
|
||||
|
Loading…
Reference in New Issue
Block a user