]> git.saurik.com Git - wxWidgets.git/commit
* Implemented according to Apple CFSocket documentation:
authorDavid Elliott <dfe@tgwbd.org>
Wed, 24 Dec 2003 04:04:40 +0000 (04:04 +0000)
committerDavid Elliott <dfe@tgwbd.org>
Wed, 24 Dec 2003 04:04:40 +0000 (04:04 +0000)
commita38b65ab35a40840d7799e8e67b781ca7474e505
treee67c2f1e55c5a3bf351f583e13c5b6062ca39bf2
parentdae0faa6be08c5bb5635fd464b695ac8bb8f2b8d
* Implemented according to Apple CFSocket documentation:
  kCFSocketConnectCallBack: Called in response to a successful connect() and
    of course applies to client sockets only. Fails assertion if received
    from a server socket. Calls GSocket's Detected_Write otherwise.
  kCFSocketReadCallBack: Called whenever data is available to read or in
    the event that a new connection is waiting to be accepted. Call's
    GSocket's Detected_Read.
  kCFSocketWriteCallBack: Called whenever data can be written to kernel buffer.
    Call's GSocket's Detected_Write
* Added ALL_CALLBACK_TYPES macro which specifies all of the above three.
* Added (by virtue of ALL_CALLBACK_TYPES) the kCFSocketConnectCallBack to
  the calls to CFSocketCreateWithNative and CFSocketDisableCallBacks during
  GUI socket data creation.
* Use the default flags for CFSocket which automatically reenable the
  callbacks, but continue to disable close of fd on CFSocket invalidation.
  Eventually, GSocket should allow the GUI implementation to override close
  so that we can avoid calling the > 10.2 CFSocketSetSocketFlags function.
* CFRelease the socket after invalidating it (fixes memory leak)
* When adding/removing callbacks use kCFSocketReadCallBack for server
  GSOCK_CONNECTION and kCFSocketConnectCallback for client.
* When adding/removing callbacks GSOCK_LOST should do the same thing as
  GSOCK_INPUT (Thanks Kevin Hock)
* When enabling events, do not enable kCFSocketConnectCallBack for servers.
  It should never be called anyway since connect() should never be used
  on a server socket.
* When disabling events, disable ALL_CALLBACK_TYPES.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@24999 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
src/mac/carbon/gsockosx.c
src/mac/gsockosx.c