mirror of
https://github.com/RGBCube/serenity
synced 2025-07-10 09:07:35 +00:00
Kernel: Fix a crash introduced by my TCP RST fix
This commit is contained in:
parent
c972afbea6
commit
6f19bf8501
1 changed files with 5 additions and 3 deletions
|
@ -410,9 +410,11 @@ void handle_tcp(IPv4Packet const& ipv4_packet, Time const& packet_timestamp)
|
|||
dbgln_if(TCP_DEBUG, "handle_tcp: looking for socket; tuple={}", tuple.to_string());
|
||||
|
||||
auto socket = TCPSocket::from_tuple(tuple);
|
||||
if (!socket && !tcp_packet.has_rst()) {
|
||||
dbgln("handle_tcp: No TCP socket for tuple {}. Sending RST.", tuple.to_string());
|
||||
send_tcp_rst(ipv4_packet, tcp_packet, adapter);
|
||||
if (!socket) {
|
||||
if (!tcp_packet.has_rst()) {
|
||||
dbgln("handle_tcp: No TCP socket for tuple {}. Sending RST.", tuple.to_string());
|
||||
send_tcp_rst(ipv4_packet, tcp_packet, adapter);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue