Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!cs.utexas.edu!usc!apple!bbn!bbn.com!pdsmith From: pdsmith@bbn.com (Peter D. Smith) Newsgroups: comp.lang.c Subject: Re: Malloc in Turbo C Message-ID: <52749@bbn.COM> Date: 28 Feb 90 14:42:55 GMT References: <26316@qfagus.OZ> <90058.153755CMH117@psuvm.psu.edu> Sender: news@bbn.COM Reply-To: pdsmith@spca.bbn.com (Peter D. Smith) Organization: Bolt Beranek and Newman Inc., Cambridge MA Lines: 20 In article <90058.153755CMH117@psuvm.psu.edu> CMH117@psuvm.psu.edu (Charles Hannum) writes: > >As a side note: No insult intended against you, but this is a prime example >of why we need to teach people a programming language before we expect them >to use it. The concept of pointers is so basic to the C language that it seems >impossible that you've had any formal education in the language. Is it that >you've never had the opportunity, never had the time, or never had the need >before? And have you considered taking a class (assuming one is available)? > C'mon lay off the guy. Malloc and Free are tough to get right. A story: at a previous job, we built a run time allocation checker (bounds checking, freeing the same memory twice, freeing a pointer after incrementing it, not freeing memory, allocation statistics... the whole ball of wax). **Every single library** by **every single C engineer** had problems! Most implementations of C are screwed up: they give you a dangerous tool but don't give you a handle on double-checking the results. Peter D. Smith