Bug fixes
This commit is contained in:
+6
-18
@@ -61,21 +61,8 @@
|
||||
typedef uint32_t SocketHandle;
|
||||
#define SOCKET_HANDLE_INVALID ((SocketHandle) 0)
|
||||
|
||||
typedef struct {
|
||||
char *ptr;
|
||||
int len;
|
||||
} String;
|
||||
|
||||
typedef uint16_t Port;
|
||||
|
||||
typedef struct {
|
||||
uint32_t data;
|
||||
} IPv4;
|
||||
|
||||
typedef struct {
|
||||
uint16_t data[8];
|
||||
} IPv6;
|
||||
|
||||
typedef enum {
|
||||
SOCKET_EVENT_READY,
|
||||
SOCKET_EVENT_DISCONNECT,
|
||||
@@ -136,8 +123,8 @@ typedef struct {
|
||||
// Internal use only
|
||||
typedef struct {
|
||||
union {
|
||||
IPv4 ipv4;
|
||||
IPv6 ipv6;
|
||||
HTTP_IPv4 ipv4;
|
||||
HTTP_IPv6 ipv6;
|
||||
};
|
||||
bool is_ipv4;
|
||||
Port port;
|
||||
@@ -183,6 +170,7 @@ typedef struct {
|
||||
};
|
||||
|
||||
#ifdef HTTPS_ENABLED
|
||||
ClientSecureContext *client_secure_context;
|
||||
ServerSecureContext *server_secure_context;
|
||||
SSL *ssl;
|
||||
#endif
|
||||
@@ -313,9 +301,9 @@ typedef struct {
|
||||
ConnectTargetType type;
|
||||
Port port;
|
||||
union {
|
||||
IPv4 ipv4;
|
||||
IPv6 ipv6;
|
||||
String name;
|
||||
HTTP_IPv4 ipv4;
|
||||
HTTP_IPv6 ipv6;
|
||||
HTTP_String name;
|
||||
};
|
||||
} ConnectTarget;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user