Re: Win32Lib changes
- Posted by Greg Harris <blackdog at CDC.NET> Dec 07, 1998
- 321 views
On Mon, 7 Dec 1998 23:17:25 +0100, Ralf Nieuwenhuijsen wrote: >>[Memory Leaks?] >I dont think many people fixed allocate_string and those routines. >They contain leaks, something that should be fixed for ver2.1 but Robert >already knows about it, Im sure. However, this could cause a memory leak as >well as the page fault.. however im not that sure the page fault would occur >in exw itself.. hmm, I sure hope it isnt a bug in exw itself.. There is a potential bug in Win32lib similar to the allocate_string bug: Currently: global function allocate_struct( integer size) -- allocate space for a structure -- and initialize to zero atom at at = allocate( size ) mem_set( at, 0, size ) return at end function Should(?) change to: global function allocate_struct( integer size) -- allocate space for a structure -- and initialize to zero atom at at = allocate( size ) if at != 0 then mem_set( at, 0, size ) return at end if return 0 end function Greg Harris HHS