home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!charon.amdahl.com!pacbell.com!decwrl!hal.com!olivea!charnel!csusac!cdsac!scotte
- From: scotte@cdsac.uucp (L. Scott Emmons)
- Newsgroups: comp.unix.aix
- Subject: Re: Divide by Zero trapping
- Message-ID: <Nov05.162951.20392@cdsac.uucp>
- Date: 5 Nov 92 16:29:51 GMT
- References: <1992Nov3.183201.16550@versyss.com>
- Organization: CableData (U.S. Computer Services), Sacramento, CA
- Lines: 24
- NntpPostingHost: cdsac
-
- In article <1992Nov3.183201.16550@versyss.com> keithd@versyss.UUCP (Keith Doyle) writes:
- >
- >I discovered that AIX does not automatically trap divide by zero. My
- >first reaction was to proclaim it a bug and post the news here, but
- >I figured I should read InfoExplorer first to find out if there is
- >any information about it. I did a search for "divide by zero" and
- >found a sample program that is supposed to trap such things under
- >XL C FloatingPoint Options. However, I can't make it work. Here
- >is my test program:
- [...]
- > signal(SIGTRAP,fhandler);
- [...]
-
- Try using SIGFPE, which will trap floating point exceptions such as
- divide by zero. This is a POSIX signal.
-
- You may want to report the documentation defect to IBM they do care.
-
- Hope this helps,
-
- L. Scott Emmons
- CableData Research Center
- csusac.csus.edu!cdsac!scotte
- KC6NFP
-