aboutgitcodebugslistschat
diff options
context:
space:
mode:
authorStefan Hajnoczi <stefanha@redhat.com>2021-10-15 11:27:17 +0100
committerStefano Brivio <sbrivio@redhat.com>2021-10-15 20:46:17 +0200
commit14fe73e766206c71ab3c6d5ddc252435c36423bd (patch)
tree1cb9f8286635432839c42c159370460300b41971
parent6231422dfb33bdc81eac5a69ca99b968964956f4 (diff)
downloadpasst-14fe73e766206c71ab3c6d5ddc252435c36423bd.tar
passt-14fe73e766206c71ab3c6d5ddc252435c36423bd.tar.gz
passt-14fe73e766206c71ab3c6d5ddc252435c36423bd.tar.bz2
passt-14fe73e766206c71ab3c6d5ddc252435c36423bd.tar.lz
passt-14fe73e766206c71ab3c6d5ddc252435c36423bd.tar.xz
passt-14fe73e766206c71ab3c6d5ddc252435c36423bd.tar.zst
passt-14fe73e766206c71ab3c6d5ddc252435c36423bd.zip
udp: drop bogus udp_tap_map ts assignment
The 'ts' field is a timestamp so assigning the socket file descriptor is incorrect. There is no actual bug because the current time is assigned just a few lines later: udp_tap_map[V4][src].sock = s; udp_tap_map[V4][src].ts = s; ^^^^^^^^^^^ bogus ^^^^^^^^^^ bitmap_set(udp_act[V4][UDP_ACT_TAP], src); } udp_tap_map[V4][src].ts = now->tv_sec; ^^^^^^^^^^^^^^^ correct ^^^^^^^^^^^^^^ Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
-rw-r--r--udp.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/udp.c b/udp.c
index 148b06a..ceb10a6 100644
--- a/udp.c
+++ b/udp.c
@@ -927,7 +927,6 @@ int udp_tap_handler(struct ctx *c, int af, void *addr,
return count;
udp_tap_map[V4][src].sock = s;
- udp_tap_map[V4][src].ts = s;
bitmap_set(udp_act[V4][UDP_ACT_TAP], src);
}