[originally from svn r218]
-/* $Id: opentpt.c,v 1.1.2.3 1999/09/01 22:24:41 ben Exp $ */
+/* $Id: opentpt.c,v 1.1.2.4 1999/09/07 23:41:32 ben Exp $ */
/*
* Copyright (c) 1999 Ben Harris
* All rights reserved.
/*
* Copyright (c) 1999 Ben Harris
* All rights reserved.
#include <OpenTransport.h>
#include <OpenTptInternet.h>
#include <OpenTransport.h>
#include <OpenTptInternet.h>
#include <stdio.h>
#include <string.h>
#include <stdio.h>
#include <string.h>
TCall remote;
DNSAddress *remoteaddr;
TCall remote;
DNSAddress *remoteaddr;
+ assert(otpt_config != kOTInvalidConfigurationPtr);
s = smalloc(sizeof(*s));
memset(s, 0, sizeof(*s));
s = smalloc(sizeof(*s));
memset(s, 0, sizeof(*s));
/* Get a TCP endpoint (equiv of socket()) */
s->ep = OTOpenEndpoint(OTCloneConfiguration(otpt_config), 0, NULL, &err);
/* Get a TCP endpoint (equiv of socket()) */
s->ep = OTOpenEndpoint(OTCloneConfiguration(otpt_config), 0, NULL, &err);
* -3199.
*/
status = OTRcvDisconnect(s->ep, &discon);
* -3199.
*/
status = OTRcvDisconnect(s->ep, &discon);
if (cookie == NULL) /* spontaneous disconnect */
switch (E2OSStatus(discon.reason)) {
case kECONNRESETErr:
if (cookie == NULL) /* spontaneous disconnect */
switch (E2OSStatus(discon.reason)) {
case kECONNRESETErr: