From: enlar AT hidespam DOT iname DOT com (Eneko Lacunza) Newsgroups: comp.os.msdos.djgpp Subject: Re: Help - Floating Point Exception Date: Sat, 26 Sep 1998 14:42:37 +0200 Organization: Telefonica Transmision de Datos Lines: 44 Message-ID: References: <6ufv25$a6e$1 AT star DOT cs DOT vu DOT nl> NNTP-Posting-Host: infon39.jet.es Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk Path: news.vitts.com!news-pen-2.sprintlink.net!news-east.sprintlink.net!news-peer.sprintlink.net!news.sprintlink.net!news-peer.gip.net!news-raspail.gip.net!news.gsl.net!gip.net!news.belnet.be!news.rediris.es!newsfeed.mad.ibernet.es!news.mad.ibernet.es!not-for-mail Xref: news.vitts.com comp.os.msdos.djgpp:75150 Hello Boon! In Viernes 25 Septiembre 1998 at 11:33, Boon van der RJ wrote to All: >> angulo=atan2((xcont-160),(100-ycont)); BvdR> atan2(0,0) might be handled not quite right, so that >> table[xcont][ycont][1]=floor(255*angulo/(2*pi)); // FPE BvdR> floor crashes. This seemed to be the problem. I set up a check so that I hardcoded angulo's value when atan2(0,0), and it now works allways. >> (i.e. running it under rhide) and if I try to redir the crash, redir >> crashes when the program has finished the above code and is doing >> something else. BvdR> In a dos-box under windows 95, you can mark the screen and paste in a BvdR> text-file, maybe that helps. Good point, I didn't think in it! 8-) >> fix it (if this info is enough). I'm using GCC 2.7.2... BvdR> Do you compile with -lm, or do you use the standards in libc? libm BvdR> does some more checking (if I've understood correctly) I use standards... libm is faster than standard lib? BvdR> What type of computer do you use? (386/486/pentiumII?) Plain Pentium. It's strange, I don't understand why it crashed under command.com but it didn't under rhide, for example. 8-) Thank you very much for your *fast* help! 8-) Regards, Eneko Lacunza. enlar/Genesis Fidonet 2:344/19.11 Fidonet forever! e-mail strip hidespam. from header's address http web.jet.es/enlar