X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;f=src%2Finternal.h;h=59eca2ad34ed70a54ebc30aadb05c17b87a62e8f;hb=f195c1bda3616129bc28d33aae71f9d2dd9047ce;hp=6c602d7deb3deb33eeaa41f27a3981d76800b893;hpb=d80c70d36363762e0cf1534e654e122d741fbc5d;p=catta diff --git a/src/internal.h b/src/internal.h index 6c602d7..59eca2a 100644 --- a/src/internal.h +++ b/src/internal.h @@ -48,6 +48,16 @@ typedef struct CattaEntry CattaEntry; #define CATTA_RR_HOLDOFF_MSEC_RATE_LIMIT 20000 #define CATTA_RR_RATE_LIMIT_COUNT 15 +#ifndef _WIN32 +#define closesocket close +#define closepipe close +#define writepipe write +#define readpipe read +#define winsock_init() +#define winsock_exit() +#define errnostrsocket() strerror(errno) +#endif + typedef struct CattaLegacyUnicastReflectSlot CattaLegacyUnicastReflectSlot; struct CattaLegacyUnicastReflectSlot { @@ -56,7 +66,7 @@ struct CattaLegacyUnicastReflectSlot { uint16_t id, original_id; CattaAddress address; uint16_t port; - int iface; + CattaIfIndex iface; struct timeval elapse_time; CattaTimeEvent *time_event; };