Path: utzoo!utgpu!utstat!jarvis.csri.toronto.edu!mailrus!wuarchive!gem.mps.ohio-state.edu!ginosko!uunet!mcsun!sunic!draken!paf From: paf@nada.kth.se (Patrik F{ltstr|m) Newsgroups: comp.sys.mac Subject: Re: Need help in THINK C Message-ID: <2150@draken.nada.kth.se> Date: 24 Oct 89 07:56:40 GMT References: <5306@lindy.Stanford.EDU> <15790@netnews.upenn.edu> <2393@eagle.wesleyan.edu> Reply-To: paf@nada.kth.se (Patrik F{ltstr|m) Organization: Royal Institute of Technology, Stockholm, Sweden Lines: 16 In article <2393@eagle.wesleyan.edu> rsilverman@eagle.wesleyan.edu writes: >Remember, it will return it as a Pascal string, so you'll have to add the NUL >yourself. It's not suprising that it's locking up on you: the text your >copying, even if it's the right part, will not have a NUL at the end, so strcpy >will happily keep copying for quite a while, overwriting all sorts of stuff -- >including your code, perhaps? -- at the destination. Use the function char *CtoPstr(char *s); /* Page 121 in Thinc C 4.0 manual */ >Ah, for a protected-mode operating system... Will that be in 8.0? > Richard Silverman Patrik F{ltstr|m