🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.dec
Article #1628

Re: VMS4.5 CRTL fstat does not free() malloc()ed memory (apparently)

#1628
From: Bradford R. Daniels
Date: Thu, 14 Jun 1990 20:53
13 lines
1253 bytes
The problem is that fstat() calls getenv(), which allocates memory for
its return value.  There is a fixed version of getenv() which keeps
around old results so that it doesn't need to allocate memory every
time.  It will be available in "a future release of VMS", no doubt...

Your work-around is the best solution for now.

- Brad

-----------------------------------------------------------------
Brad Daniels			|  Digital Equipment Corp. almost
DEC Software Devo		|  definitely wouldn't approve of
"VAX C RTL Whipping Boy"	|  anything I say here...
Technical Details
Message-ID: <12498@shlump.nac.dec.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!sdd.hp.com!decwrl!shlump.nac.dec.com!hanoi.enet.dec.com!daniels
References: <1990Jun6.233823.16060@murdoch.acc.Virginia.EDU>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!sdd.hp.com!decwrl!shlump.nac.dec.com!hanoi.enet.dec.com!daniels
From: daniels@hanoi.enet.dec.com (Bradford R. Daniels)
Newsgroups: comp.sys.dec,comp.os.vms
Subject: Re: VMS4.5 CRTL fstat does not free() malloc()ed memory (apparently)
Keywords: fstat malloc free VAXCRTL memory
Message-ID: <12498@shlump.nac.dec.com>
Date: 14 Jun 90 20:53:50 GMT
References: <1990Jun6.233823.16060@murdoch.acc.Virginia.EDU>
Sender: newsdaemon@shlump.nac.dec.com
Reply-To: daniels@hanoi.enet.dec.com (Bradford R. Daniels)
Followup-To: comp.sys.dec
Organization: Digital Equipment Corp.
Lines: 13