Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!snorkelwacker.mit.edu!thunder.mcrcim.mcgill.edu!poly-vlsi!big From: big@vlsi.polymtl.ca (Patrick Drolet) Newsgroups: comp.os.msdos.programmer Subject: Re: scanf bug in TC Message-ID: <1991Mar8.194255.17091@vlsi.polymtl.ca> Date: 8 Mar 91 19:42:55 GMT References: <1991Mar4.190946.26628@novell.com> Sender: news@vlsi.polymtl.ca (USENET News System) Organization: Ecole Polytechnique de Montreal Lines: 41 In article <1991Mar4.190946.26628@novell.com> tporczyk@na.excelan.com (Tony Porczyk) writes: >The News Manager) >Nntp-Posting-Host: na >Reply-To: tporczyk@na.excelan.com (Tony Porczyk) >Organization: Standard Disclaimer >References: <1991Mar4.152035.13078@ux1.cso.uiuc.edu> >Distribution: usa >Date: Mon, 4 Mar 1991 19:09:46 GMT > >In article <1991Mar4.152035.13078@ux1.cso.uiuc.edu> vernon@blueeyes.kines.uiuc.edu (vernon) writes: >>scanf: floating point formats not linked >>abnormal program termination >>I have been informed that this is a bug in TC, but that there is kludge > >Bug? Kludge? Before we get into that - did you #include >Tony > > Ok, a friend of mine had a similar bug using atof(). He fixed it using a dumb procedure (that he even never called!) so the linker would not forget to link everything needed on floats... procedure is the following: float linkfloat( float *f1 ) { float f2 = *f1; linkfloat(*f2); return 0.0; } He told me that he got this information from Borland tech support... MAKE SURE SUCH PROCEDUREIS IN YOUR CODE BUT DO NOT CALL IT!!!! Using a float address, it tells the linker to link floating stuff. Patrick Drolet big@info.polymtl.ca >