Skip to content
Snippets Groups Projects
Commit 850907a0 authored by Deucе's avatar Deucе :ok_hand_tone4:
Browse files

Make socket_send_buffer_t separate from socket_recv_buffer_t

It seems we can't add a const to a typedef in a static_cast<>()
parent 4c481b36
No related branches found
No related tags found
No related merge requests found
......@@ -28,7 +28,8 @@
/* OS-specific */
/***************/
#if defined(_WIN32) /* Use WinSock */
typedef char* socket_buffer_t;
typedef const char* socket_send_buffer_t;
typedef char* socket_recv_buffer_t;
#ifndef _WINSOCKAPI_
#include <winsock2.h> /* socket/bind/etc. */
......@@ -51,7 +52,8 @@ typedef char* socket_buffer_t;
#endif
#elif defined __unix__ /* Unix-variant */
typedef void* socket_buffer_t;
typedef const void* socket_send_buffer_t;
typedef void* socket_recv_buffer_t;
#include <netdb.h> /* gethostbyname */
#include <sys/types.h> /* For u_int32_t on FreeBSD */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment