kire@cyklop.nada.kth.se (Jan-Erik M}ngs) (03/15/91)
Is it possible to abort an asynchronous operation in MacTCP? Here's the problem: I do a TCPPassiveOpen asynchronous to grab a unique tcp_port on my mac. That tcp_port is used when launching a server on a unix machine (using rexecd). The server is started as "server ip_addr_of_mac tcp_port_on_mac &". The first thing the server does is to disassociate itself from the tty (the shell will exit and rexecd will close its connection) and then connect to my "tcp_port_on_mac". I can now communicate with the server on my own tcp-connection. Now, if I fail to launch the server on the unix machine, no one will be there to connect to my tcp_port and would like to abort the TCPPassiveOpen operation. Can this be done or do I have to wait for timeout? ---------------- . -- Jan-Erik "Kire" Mangs kire@nada.kth.se ---------------------
urlichs@smurf.sub.org (Matthias Urlichs) (03/18/91)
In comp.sys.mac.programmer, article <KIRE.91Mar15130507@cyklop.nada.kth.se>,
kire@cyklop.nada.kth.se (Jan-Erik M}ngs) writes:
< Is it possible to abort an asynchronous operation in MacTCP?
<
Did you try TCPAbort?
It says "returns the connection to its initial state" in the manual.
If not, TCPRelease definitely should work.
--
Matthias Urlichs -- urlichs@smurf.sub.org -- urlichs@smurf.ira.uka.de /(o\
Humboldtstrasse 7 - 7500 Karlsruhe 1 - FRG -- +49-721-621127(0700-2330) \o)/
dorner@pequod.cso.uiuc.edu (Steve Dorner) (03/18/91)
>< Is it possible to abort an asynchronous operation in MacTCP? >< >Did you try TCPAbort? >If not, TCPRelease definitely should work. You'd best be darn sure you won't be getting any more packets before calling TCPRelease on a MacTCP connection. MacTCP cannot handle packets that arrive for a connection it no longer has. It seems to successfully reset the connection, but then crashes the mac horribly, at least on several flavors of Ethernet cards. -- Steve Dorner, U of Illinois Computing Services Office Internet: s-dorner@uiuc.edu UUCP: uunet!uiucuxc!uiuc.edu!s-dorner
ekalenda@cup.portal.com (Edward John Kalenda) (03/20/91)
>I do a TCPPassiveOpen asynchronous to grab a unique tcp_port on >my mac. That tcp_port is used when launching a server on a unix >machine (using rexecd). The server is started as "server >ip_addr_of_mac tcp_port_on_mac &". The first thing the server >does is to disassociate itself from the tty (the shell will exit >and rexecd will close its connection) and then connect to my >"tcp_port_on_mac". I can now communicate with the server on my >own tcp-connection. > >Now, if I fail to launch the server on the unix machine, no one >will be there to connect to my tcp_port and would like to abort >the TCPPassiveOpen operation. There is NO way to stop the PassiveOpen in the current release of MacTCP unless it has had a connection first. I and my croney at Apple has spoken to the developer of MacTCP and "It's a known bug which will be fixed just as soon as I get to it". We solved the problem by having our application connect to itself, thereby causing MacTCP to be happy since a connection to the PassiveOpen happened. Ed ekalenda@cup.portal.com
resnick@cogsci.uiuc.edu (Pete Resnick) (03/21/91)
ekalenda@cup.portal.com (Edward John Kalenda) writes: >There is NO way to stop the PassiveOpen in the current release of >MacTCP unless it has had a connection first. I and my croney at >Apple has spoken to the developer of MacTCP and "It's a known bug >which will be fixed just as soon as I get to it". We solved the >problem by having our application connect to itself, thereby causing >MacTCP to be happy since a connection to the PassiveOpen happened. This is just wrong. I do it, as described in my previous post, with no problems at all. I don't know what problem you encountered, or who you spoke to at Apple, but this is just incorrect. If you need a sample piece of code that does it, write and I will send it to you. pr -- Pete Resnick (...so what is a mojo, and why would one be rising?) Graduate assistant - Philosophy Department, Gregory Hall, UIUC System manager - Cognitive Science Group, Beckman Institute, UIUC Internet/ARPAnet/EDUnet : resnick@cogsci.uiuc.edu BITNET (if no other way) : FREE0285@UIUCVMD