Page 1 of 1

Posted: Sun Mar 23, 2003 2:41 pm
by BackupUser
Restored from previous forum. Originally posted by dmoc.

I have (quickly) checked that the following does not leak memory once the program has ended but will there be memory loss if this technique is used repeatedly, poss in a procedure? To put it another way, will PB garbage collect the whole string or only upto the NULL?

buffer.s = space(1024)
SomeSysFunction_(@buffer); Returns string of len < 1024

Posted: Sun Mar 23, 2003 4:19 pm
by BackupUser
Restored from previous forum. Originally posted by fred.

It frees the whole memory buffer, no problem.

Fred - AlphaSND

Posted: Sun Mar 23, 2003 4:40 pm
by BackupUser
Restored from previous forum. Originally posted by dmoc.

Ta