C rewrite: C-ify includes (cstdio -> stdio.h)
This commit is contained in:
parent
99f14b84c1
commit
8f5d3b9805
10 changed files with 12 additions and 14 deletions
|
@ -5,8 +5,8 @@
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <cstdlib>
|
#include <stdlib.h>
|
||||||
#include <cstring>
|
#include <string.h>
|
||||||
|
|
||||||
#include "TunDevice.hpp"
|
#include "TunDevice.hpp"
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#include <cstring>
|
#include <string.h>
|
||||||
|
|
||||||
#include "UdpVpnClient.hpp"
|
#include "UdpVpnClient.hpp"
|
||||||
#include "ip_header.hpp"
|
#include "ip_header.hpp"
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#include <cstring>
|
#include <string.h>
|
||||||
|
|
||||||
#include "UdpVpnServer.hpp"
|
#include "UdpVpnServer.hpp"
|
||||||
#include "ip_header.hpp"
|
#include "ip_header.hpp"
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <unordered_map>
|
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
|
||||||
#include "UdpVpn.hpp"
|
#include "UdpVpn.hpp"
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#include "VpnPacket.hpp"
|
#include "VpnPacket.hpp"
|
||||||
#include "VpnPeer.hpp"
|
#include "VpnPeer.hpp"
|
||||||
|
|
||||||
#include <cstring>
|
#include <string.h>
|
||||||
|
|
||||||
const size_t VpnPacket::VPN_HEADER_BYTES = 8;
|
const size_t VpnPacket::VPN_HEADER_BYTES = 8;
|
||||||
const size_t VpnControlPacket::TLV_HEADER_BYTES = 3;
|
const size_t VpnControlPacket::TLV_HEADER_BYTES = 3;
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
/** A packet to be transmitted or received over the VPN socket */
|
/** A packet to be transmitted or received over the VPN socket */
|
||||||
|
|
||||||
#include <cstdlib>
|
#include <stdlib.h>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
|
||||||
#include "ip_header.hpp"
|
#include "ip_header.hpp"
|
||||||
|
|
|
@ -1,9 +1,8 @@
|
||||||
#include "UdpVpn.hpp"
|
#include "UdpVpn.hpp"
|
||||||
#include "congestion_control.hpp"
|
#include "congestion_control.hpp"
|
||||||
|
|
||||||
#include <cstdint>
|
#include <stdint.h>
|
||||||
#include <cstring>
|
#include <string.h>
|
||||||
#include <functional>
|
|
||||||
|
|
||||||
const double RTTLogger::EXP_AVG_FACTOR = 0.75;
|
const double RTTLogger::EXP_AVG_FACTOR = 0.75;
|
||||||
const unsigned int RTTLogger::BASE_UPDATE_DELAY = 1000; // ms
|
const unsigned int RTTLogger::BASE_UPDATE_DELAY = 1000; // ms
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#include <cstring>
|
#include <string.h>
|
||||||
|
|
||||||
#include "ip_header.hpp"
|
#include "ip_header.hpp"
|
||||||
#include "util.hpp"
|
#include "util.hpp"
|
||||||
|
|
4
main.cpp
4
main.cpp
|
@ -1,5 +1,5 @@
|
||||||
#include <cstdio>
|
#include <stdio.h>
|
||||||
#include <cstdlib>
|
#include <stdlib.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <arpa/inet.h>
|
#include <arpa/inet.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
|
|
2
util.cpp
2
util.cpp
|
@ -1,4 +1,4 @@
|
||||||
#include <cstdio>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <arpa/inet.h>
|
#include <arpa/inet.h>
|
||||||
|
|
Loading…
Reference in a new issue