X-Authentication-Warning: delorie.com: mailnull set sender to djgpp-workers-bounces using -f From: sandmann AT clio DOT rice DOT edu (Charles Sandmann) Message-Id: <10203022106.AA22507@clio.rice.edu> Subject: Re: Malloc/free DJGPP code To: djgpp-workers AT delorie DOT com Date: Sat, 2 Mar 2002 15:06:04 -0600 (CST) In-Reply-To: <4331-Sat02Mar2002220420+0200-eliz@is.elta.co.il> from "Eli Zaretskii" at Mar 02, 2002 10:04:20 PM X-Mailer: ELM [version 2.5 PL2] Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp-workers AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > > No great sweat doing that, but as I discovered early on malloc is > > used during initialization and if any errors occur then writing to > > stdout at least is fatal and useless. > > It's fatal if you use buffered stdio functions. If you use `write' > (or even `_write') instead, it's not fatal. The crash message is > written using these methods, and you could do the same with some > additional text you print before you abort. Example: see src/libc/go32/dpmiexcp.c If we need to print values, we might want to make the itox call global (with appropriate _ added to name) - but I think a simple line telling why we would be aborting would be fine.