*
*/
-#ifndef __LIBMEMCACHED_PROTOCOL_H__
-#define __LIBMEMCACHED_PROTOCOL_H__
+#pragma once
#include <sys/types.h>
#if !defined(__cplusplus)
* or -1 upon error (errno should contain more information)
*/
typedef ssize_t (*memcached_protocol_recv_func)(const void *cookie,
- SOCKET fd,
+ memcached_socket_t fd,
void *buf,
size_t nbuf);
* or -1 upon error (errno should contain more information)
*/
typedef ssize_t (*memcached_protocol_send_func)(const void *cookie,
- SOCKET fd,
+ memcached_socket_t fd,
const void *buf,
size_t nbuf);
* @return NULL if allocation fails, otherwise an instance
*/
LIBMEMCACHED_API
-memcached_protocol_client_st *memcached_protocol_create_client(memcached_protocol_st *instance, SOCKET sock);
+memcached_protocol_client_st *memcached_protocol_create_client(memcached_protocol_st *instance, memcached_socket_t sock);
/**
* Destroy a client handle.
* @return the socket handle
*/
LIBMEMCACHED_API
-SOCKET memcached_protocol_client_get_socket(memcached_protocol_client_st *client);
+memcached_socket_t memcached_protocol_client_get_socket(memcached_protocol_client_st *client);
/**
* Get the error id socket attached to a client handle
#ifdef __cplusplus
}
#endif
-
-#endif