diff options
author | Toni Uhlig <matzeton@googlemail.com> | 2020-05-27 20:58:03 +0200 |
---|---|---|
committer | Toni Uhlig <matzeton@googlemail.com> | 2020-05-27 20:58:03 +0200 |
commit | af15e7f597ad03d541a43199b29e422971e48ed8 (patch) | |
tree | b6e85865f64fb152d5ca612ec00f4b20df937761 | |
parent | 3ff4d34fb0bdaebcc34a06bba417eb0348e8894c (diff) |
set ip_pkt to NULL during definition
Signed-off-by: Toni Uhlig <matzeton@googlemail.com>
-rw-r--r-- | src/pkt.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -215,7 +215,7 @@ static proxy_desc_t * get_proxy_descriptor(uint16_t id_no) */ void handle_packet(char * buf, unsigned bytes, int is_pcap, struct sockaddr_in * addr, int icmp_sock) { - ip_packet_t * ip_pkt; + ip_packet_t * ip_pkt = NULL; icmp_echo_packet_t * pkt; ping_tunnel_pkt_t * pt_pkt; proxy_desc_t * cur; @@ -237,7 +237,6 @@ void handle_packet(char * buf, unsigned bytes, int is_pcap, struct sockaddr_in * } if (opts.udp || opts.unprivileged) { - ip_pkt = NULL; pkt = (icmp_echo_packet_t *)buf; pt_pkt = (ping_tunnel_pkt_t *)pkt->data; } else { |