aboutgitcodebugslistschat
path: root/log.c
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2023-12-08 01:31:37 +1100
committerStefano Brivio <sbrivio@redhat.com>2023-12-27 19:29:45 +0100
commitb9f4314ef9e7dc8b2852430f6923cbedda46ae38 (patch)
treeb6f7620e4b819017c79414366d9c38c444ecf61e /log.c
parenteae4304000cb72cbb2e422474705ab9b2e38c939 (diff)
downloadpasst-b9f4314ef9e7dc8b2852430f6923cbedda46ae38.tar
passt-b9f4314ef9e7dc8b2852430f6923cbedda46ae38.tar.gz
passt-b9f4314ef9e7dc8b2852430f6923cbedda46ae38.tar.bz2
passt-b9f4314ef9e7dc8b2852430f6923cbedda46ae38.tar.lz
passt-b9f4314ef9e7dc8b2852430f6923cbedda46ae38.tar.xz
passt-b9f4314ef9e7dc8b2852430f6923cbedda46ae38.tar.zst
passt-b9f4314ef9e7dc8b2852430f6923cbedda46ae38.zip
util: Drop explicit setting to INADDR_ANY/in6addr_any in sock_l4()
The original commit message says: --- Currently we initialise the address field of the sockaddrs we construct to the any/unspecified address, but not in a very clear way: we use explicit 0 values, which is only interpretable if you know the order of fields in the sockaddr structures. Use explicit field names, and explicit initialiser macros for the address. Because we initialise to this default value, we don't need to explicitly set the any/unspecified address later on if the caller didn't pass an overriding bind address. --- and the original patch modified the initialisation of addr4 and addr6: - instead of { 0 }, { 0 } for sin_addr and sin_zero, .sin_addr = IN4ADDR_ANY_INIT - instead of 0, IN6ADDR_ANY_INIT, 0: .sin6_addr = IN6ADDR_ANY_INIT but I dropped those hunks: they break gcc versions 7 to 9 as reported in eed6933e6c29 ("udp: Explicitly initialise sin6_scope_id and sin_zero in sockaddr_in{,6}"). I applied the rest of the changes. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> [sbrivio: Dropped first two hunks] Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'log.c')
0 files changed, 0 insertions, 0 deletions