X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/d6d6a882d4d8ea0d7ef706a45fa92b96f34c94c7..bc63f2c969b303cf5f5e7f9adc9cd7c565f1d9b0:/include/wx/mac/carbon/gsockmac.h diff --git a/include/wx/mac/carbon/gsockmac.h b/include/wx/mac/carbon/gsockmac.h index 2dcdbe65e0..de035d0d40 100644 --- a/include/wx/mac/carbon/gsockmac.h +++ b/include/wx/mac/carbon/gsockmac.h @@ -1,8 +1,10 @@ /* ------------------------------------------------------------------------- - * Project: GSocket (Generic Socket) for WX - * Name: gsockunx.h - * Purpose: GSocket Macintosh header - * CVSID: $Id$ + * Project: GSocket (Generic Socket) for WX + * Name: gsockunx.h + * Copyright: (c) Guilhem Lavaux + * Licence: wxWindows Licence + * Purpose: GSocket Macintosh header + * CVSID: $Id$ * ------------------------------------------------------------------------- */ @@ -21,19 +23,25 @@ #include "gsocket.h" #endif +#ifndef OTUNIXERRORS + #include #define OTUNIXERRORS 1 +// we get a conflict in OT headers otherwise : +#undef EDEADLK #include #include #include +#endif + /* Definition of GSocket */ class GSocket { public: GSocket(); ~GSocket(); - bool IsOK() { return m_ok; } + bool IsOk() { return m_ok; } void Shutdown(); GSocketError SetLocal(GAddress *address); @@ -42,13 +50,13 @@ public: GAddress *GetPeer(); GSocketError SetServer(); GSocket *WaitConnection(); - int SetReusable() { return 0; } + bool SetReusable() { return false; } GSocketError SetNonOriented(); GSocketError Connect(GSocketStream stream); int Read(char *buffer, int size); int Write(const char *buffer, int size); GSocketEventFlags Select(GSocketEventFlags flags); - void SetNonBlocking(int non_block); + void SetNonBlocking(bool non_block); void SetTimeout(unsigned long millisec); GSocketError WXDLLIMPEXP_NET GetError(); void SetCallback(GSocketEventFlags flags, @@ -83,17 +91,17 @@ public: GAddress *m_peer; GSocketError m_error; - int m_non_blocking; - int m_server; - int m_stream; - int m_oriented; + bool m_non_blocking; + bool m_server; + bool m_stream; + bool m_oriented; unsigned long m_timeout; /* Callbacks */ GSocketEventFlags m_detected; GSocketCallback m_cbacks[GSOCK_MAX_EVENT]; char *m_data[GSOCK_MAX_EVENT]; - int m_takesEvents ; + bool m_takesEvents ; };