From c74ac8b84408bd083f71e8e078f75d66acbcf0fd Mon Sep 17 00:00:00 2001 From: lsalzman Date: Wed, 3 Oct 2012 16:26:18 +0300 Subject: forward declare some structs to fix compile errors --- include/enet/enet.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/enet/enet.h b/include/enet/enet.h index 90fdbfd..32671e8 100644 --- a/include/enet/enet.h +++ b/include/enet/enet.h @@ -31,6 +31,10 @@ extern "C" typedef enet_uint32 ENetVersion; +struct _ENetHost; +struct _ENetEvent; +struct _ENetPacket; + typedef enum _ENetSocketType { ENET_SOCKET_TYPE_STREAM = 1, @@ -111,7 +115,6 @@ typedef enum _ENetPacketFlag ENET_PACKET_FLAG_UNRELIABLE_FRAGMENT = (1 << 3) } ENetPacketFlag; -struct _ENetPacket; typedef void (ENET_CALLBACK * ENetPacketFreeCallback) (struct _ENetPacket *); /** @@ -321,7 +324,7 @@ typedef struct _ENetCompressor typedef enet_uint32 (ENET_CALLBACK * ENetChecksumCallback) (const ENetBuffer * buffers, size_t bufferCount); /** Callback for intercepting received raw UDP packets. Should return 1 to intercept, 0 to ignore, or -1 to propagate an error. */ -typedef int (ENET_CALLBACK * ENetInterceptCallback) (ENetHost * host, ENetEvent * event); +typedef int (ENET_CALLBACK * ENetInterceptCallback) (struct _ENetHost * host, struct _ENetEvent * event); /** An ENet host for communicating with peers. * -- cgit v1.2.3