diff options
| author | Jon Maloy <jmaloy@redhat.com> | 2026-07-09 17:56:51 -0400 |
|---|---|---|
| committer | Stefano Brivio <sbrivio@redhat.com> | 2026-07-15 23:18:38 +0200 |
| commit | 80cb5cf5a9b1b16a30c8ae4c47a87c8bfc91f20c (patch) | |
| tree | ae6b12005b3163429397ef68bc9ced23033b0b11 | |
| parent | fc6c774f6705800cc9409713e678001ca6c4a581 (diff) | |
| download | passt-80cb5cf5a9b1b16a30c8ae4c47a87c8bfc91f20c.tar passt-80cb5cf5a9b1b16a30c8ae4c47a87c8bfc91f20c.tar.gz passt-80cb5cf5a9b1b16a30c8ae4c47a87c8bfc91f20c.tar.bz2 passt-80cb5cf5a9b1b16a30c8ae4c47a87c8bfc91f20c.tar.lz passt-80cb5cf5a9b1b16a30c8ae4c47a87c8bfc91f20c.tar.xz passt-80cb5cf5a9b1b16a30c8ae4c47a87c8bfc91f20c.tar.zst passt-80cb5cf5a9b1b16a30c8ae4c47a87c8bfc91f20c.zip | |
passt: Initialise listening socket fds to -1
fd_tap_listen, fd_control_listen, and fd_repair_listen are file
descriptors and should be initialised to -1 rather than the implicit
0, consistent with the other fd fields in passt_ctx.
Signed-off-by: Jon Maloy <jmaloy@redhat.com>
Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
| -rw-r--r-- | passt.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -65,6 +65,9 @@ char pkt_buf[PKT_BUF_BYTES] __attribute__ ((aligned(PAGE_SIZE))); struct ctx passt_ctx = { .pidfile_fd = -1, .fd_tap = -1, + .fd_tap_listen = -1, + .fd_control_listen = -1, + .fd_repair_listen = -1, .pasta_netns_fd = -1, .device_state_fd = -1, }; |
