diff options
author | Tobias Klauser <tklauser@distanz.ch> | 2014-05-09 14:22:25 +0200 |
---|---|---|
committer | Tobias Klauser <tklauser@distanz.ch> | 2014-05-09 14:22:25 +0200 |
commit | d1a16d34e7828150403dec6da1fb6ba75c7ca1ad (patch) | |
tree | 15a942226b8dd883a389ce00b7898b9cb2568170 /netsniff-ng.c | |
parent | 132f533dac7211d0d98bf3e56112db156a4b2cf7 (diff) |
netsniff-ng: Remove unnecessary memset of struct pollfd
rx_poll will be passed to prepare_polling() which already zeros the
struct, so no need to do it before.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Diffstat (limited to 'netsniff-ng.c')
-rw-r--r-- | netsniff-ng.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/netsniff-ng.c b/netsniff-ng.c index 5ce64e5..f22137d 100644 --- a/netsniff-ng.c +++ b/netsniff-ng.c @@ -364,7 +364,6 @@ static void receive_to_xmit(struct ctx *ctx) fmemset(&tx_ring, 0, sizeof(tx_ring)); fmemset(&rx_ring, 0, sizeof(rx_ring)); - fmemset(&rx_poll, 0, sizeof(rx_poll)); fmemset(&bpf_ops, 0, sizeof(bpf_ops)); ifindex_in = device_ifindex(ctx->device_in); @@ -902,7 +901,6 @@ static void recv_only_or_dump(struct ctx *ctx) } fmemset(&rx_ring, 0, sizeof(rx_ring)); - fmemset(&rx_poll, 0, sizeof(rx_poll)); fmemset(&bpf_ops, 0, sizeof(bpf_ops)); ifindex = device_ifindex(ctx->device_in); |