|
|
@ -21,6 +21,8 @@
|
|
|
|
#include "hal_socket.h"
|
|
|
|
#include "hal_socket.h"
|
|
|
|
#include "stack_config.h"
|
|
|
|
#include "stack_config.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#define DEBUG_SOCKET 1
|
|
|
|
|
|
|
|
|
|
|
|
#ifndef __MINGW64_VERSION_MAJOR
|
|
|
|
#ifndef __MINGW64_VERSION_MAJOR
|
|
|
|
struct tcp_keepalive {
|
|
|
|
struct tcp_keepalive {
|
|
|
|
u_long onoff;
|
|
|
|
u_long onoff;
|
|
|
@ -671,6 +673,9 @@ Socket_destroy(Socket self)
|
|
|
|
static UdpSocket
|
|
|
|
static UdpSocket
|
|
|
|
UdpSocket_createUsingNamespace(int ns)
|
|
|
|
UdpSocket_createUsingNamespace(int ns)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
if (wsaStartUp() == false)
|
|
|
|
|
|
|
|
return NULL;
|
|
|
|
|
|
|
|
|
|
|
|
UdpSocket self = NULL;
|
|
|
|
UdpSocket self = NULL;
|
|
|
|
|
|
|
|
|
|
|
|
SOCKET sock = socket(AF_INET, SOCK_DGRAM, 0);
|
|
|
|
SOCKET sock = socket(AF_INET, SOCK_DGRAM, 0);
|
|
|
|