1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-28 10:25:10 +00:00

Everywhere: Run clang-format

This commit is contained in:
Idan Horowitz 2022-04-01 20:58:27 +03:00 committed by Linus Groh
parent 0376c127f6
commit 086969277e
1665 changed files with 8479 additions and 8479 deletions

View file

@ -28,7 +28,7 @@ void NetworkAdapter::send_packet(ReadonlyBytes packet)
send_raw(packet);
}
void NetworkAdapter::send(const MACAddress& destination, const ARPPacket& packet)
void NetworkAdapter::send(MACAddress const& destination, ARPPacket const& packet)
{
size_t size_in_bytes = sizeof(EthernetFrameHeader) + sizeof(ARPPacket);
auto buffer_result = NetworkByteBuffer::create_zeroed(size_in_bytes);
@ -41,7 +41,7 @@ void NetworkAdapter::send(const MACAddress& destination, const ARPPacket& packet
eth->set_destination(destination);
eth->set_ether_type(EtherType::ARP);
memcpy(eth->payload(), &packet, sizeof(ARPPacket));
send_packet({ (const u8*)eth, size_in_bytes });
send_packet({ (u8 const*)eth, size_in_bytes });
}
void NetworkAdapter::fill_in_ipv4_header(PacketWithTimestamp& packet, IPv4Address const& source_ipv4, MACAddress const& destination_mac, IPv4Address const& destination_ipv4, IPv4Protocol protocol, size_t payload_size, u8 type_of_service, u8 ttl)
@ -149,17 +149,17 @@ void NetworkAdapter::release_packet_buffer(PacketWithTimestamp& packet)
m_unused_packets.append(packet);
}
void NetworkAdapter::set_ipv4_address(const IPv4Address& address)
void NetworkAdapter::set_ipv4_address(IPv4Address const& address)
{
m_ipv4_address = address;
}
void NetworkAdapter::set_ipv4_netmask(const IPv4Address& netmask)
void NetworkAdapter::set_ipv4_netmask(IPv4Address const& netmask)
{
m_ipv4_netmask = netmask;
}
void NetworkAdapter::set_ipv4_gateway(const IPv4Address& gateway)
void NetworkAdapter::set_ipv4_gateway(IPv4Address const& gateway)
{
m_ipv4_gateway = gateway;
}