Drop handle_udp parameter threading: ipv4::handle calls net_handle_udp directly
This commit is contained in:
@@ -28,7 +28,7 @@ void net_send_raw(std::span<const uint8_t> data) {
|
||||
});
|
||||
}
|
||||
|
||||
static void handle_udp(std::span<const uint8_t> frame, span_writer& tx) {
|
||||
void net_handle_udp(std::span<const uint8_t> frame, span_writer& tx) {
|
||||
parse_buffer pb(frame);
|
||||
auto* eth_hdr = pb.consume<eth::header>();
|
||||
auto* ip = pb.consume<ipv4::header>();
|
||||
@@ -84,7 +84,7 @@ static void process_frame(std::span<const uint8_t> frame, span_writer& tx) {
|
||||
arp::handle(frame, tx, state.mac, state.ip);
|
||||
break;
|
||||
case eth::ETH_IPV4:
|
||||
ipv4::handle(frame, tx, state.mac, state.ip, IP_BROADCAST_SUBNET, handle_udp);
|
||||
ipv4::handle(frame, tx, state.mac, state.ip, IP_BROADCAST_SUBNET);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user