home *** CD-ROM | disk | FTP | other *** search
Text File | 1995-01-04 | 1.4 KB | 49 lines | [TEXT/MMCC] |
- //
- // TCPCompletionProc.cp
- //
- // TurboTCP library
- // TCP asynchronous call completion procedure
- // 68K code resource for PowerPC applications
- //
- // Copyright © 1993-95, FrostByte Design / Eric Scouten
- //
-
- // •• THIS FILE SHOULD NOT BE INCLUDED IN PowerPC BUILDS! ••
-
- #include "TurboTCP.buildflags.h"
- #include "TurboTCP.types.h"
-
- #ifndef __MWERKS__
- //#pragma options(!force_frame, !profile)
- #else
- #pragma profile off
- #pragma a6frames off
- #endif
-
- #if TurboTCP_PPC
- #error Do not include this file in PowerPC builds!
- #endif
-
-
- //***********************************************************
-
- #pragma parameter main(__A0)
- void main(struct TurboTCPiopb* iopb)
-
- // The asynchronous completion routine. Recieves notification that any asynchronous
- // TCP I/O operation has been completed. This routine is used for all TCP calls placed by
- // CTCPAsyncCall::DoAsyncCall.
- //
- // Send notification to the TCP driver object that this call has been completed. The driver
- // then queues the call for processing at the next event loop.
- //
- // The struct TurboTCPiopb includes a pointer to the CTCPDriver queue so that we don’t
- // need to access application globals in this loop. This improves performance, and
- // also permits us to use a 68K code resource in an otherwise PowerPC environment
- // to avoid the performance hit of mode switches.
-
- {
- ::Enqueue((QElemPtr) &(iopb->itsQElem), iopb->itsQueue);
- // CTCPDriver::ProcessNetEvents will pick this up later
- }
-