Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!uwm.edu!ogicse!zephyr.ens.tek.com!gvgpsa!treehouse!andyp From: andyp@treehouse.UUCP (Andy Peterman) Newsgroups: comp.sys.mac.programmer Subject: Re: AppleTalk - ATPCloseSocket Keywords: AppleTalk Message-ID: <833@treehouse.UUCP> Date: 18 Mar 91 23:34:34 GMT References: <2859@sparko.gwu.edu> Reply-To: treehouse!andyp@gvgpsa.gvg.tek.com Organization: The Treehouse Lines: 25 In article <2859@sparko.gwu.edu> rjohnson@seas.gwu.edu (Ray Johnson) writes: >I open up a socket and name it useing ATPOpenSocket and PRegisterName and >everything seems fine with no errors. However, when I try to close the >socket with ATPCloseSocket I get the error badATPskt (-1099). Why would >it be giving that error? Anyone? Anyone? This is a long shot, but try changing the entry for that call in Appletalk.h so that you're passing a short instead of a char. For example, the line should read: pascal OSErr ATPCloseSocket(short atpSocket); ^^^^^ I'm not sure if this is the problem, but it may fix it. I had a similar problem with DDPCloseSocket and, while tracing the code, found that the library routine pulled a word (16 bit value) off the stack. I have since found a work-around and never tried fixing it this way. Let me know if it works - I've been meaning to test it and pass it on to MPW.BUGS at Apple if there is indeed a problem. -- Andy Peterman | Opinions expressed treehouse!andyp@gvgpsa.gvg.tek.com | are definitely those of (916) 273-4569 | my employer!