home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!mcsun!chsun!zurich!gegu
- From: gegu@zurich.spectrospin.ch (Gerry Gucher)
- Newsgroups: comp.lang.c
- Subject: Re: Unsolveable bug
- Summary: malloc problem is probably a programmer problem
- Message-ID: <204@zurich.spectrospin.ch>
- Date: 6 Jan 93 16:16:19 GMT
- References: <1hq27eINNjv@uwm.edu>
- Organization: Spectrospin AG, Fallanden Switzerland
- Lines: 46
-
- In article <1hq27eINNjv@uwm.edu>, markh@csd4.csd.uwm.edu (Mark) writes:
- >
- > I've run into an unsolveable bug. The bug comes from no visible error, it
- > disappears when searched for under a debugger, and it's likewise non-existent
- > when the same program is run under other platforms and compilers. And it
- > doesn't involve anything having to do with timing of any sort.
- >
- > It appears on the DOS port of the program and causes the machine to crash
- > immediately after a call to malloc(). The malloc call is the ANSI-compatible
- > call, declared with the <stdlib.h> header. The particular usage leading to
- > the crash is (as determined by traces): malloc(16), malloc(16), malloc(20), ...
- > with no intervening free() calls. All calls to malloc() return valid pointers.
- > Checking the memory usage reveals no corruption or access out of bounds.
-
- You probably haven't checked carefully enough.
-
- >
- > The compiler creating the problem has had reliable error-free performance
- > with other similar programs.
-
- Have you also checked the programmer for reliable error-free performance with
- other similar programs ?
-
- It would help much if you could could state the kind of system and OS you are
- using. Code might help too, but its unlikely because the source of the error
- is probably far away from the place where the crash occurred.
-
- If you are working on a Sun workstation do yourself a favor and
- use "malloc_debug" and if this not sufficient get a copy of the "Purify"
- package from Pure Software (CA +(408) 720-1600). Price is approx. ~1900
- UK pounds. I don't know the price in US$.
-
- I have no relationship to "Pure" except being a satisfied customer. (This is
- quite tough to achieve).
-
- Gerry
-
-
- +------------------------------------------------------------------+
- | Gerry Gucher gegu@spectrospin.ch |
- | Spectrospin AG, Industriestr 26, 8117 Faellanden Switzerland |
- +------------------------------------------------------------------+
- | A program that returns the wrong | There is nothing wrong with |
- | result twice as fast is infinitely | making mistakes, but make |
- | slower. - H. Spencer | new ones. - D.Sim |
- +------------------------------------------------------------------+
-