Kbase P89053: Does doing an UNDO, RETURN when there is an active dynamic buffer cause a memory leak?
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  03/02/2011 |
|
Status: Verified
GOAL:
Does doing an UNDO, RETURN when there is an active dynamic buffer cause a memory leak?
FACT(s) (Environment):
All Supported Operating Systems
OpenEdge 10.x
FIX:
Yes, it does. Dynamic buffers must be deleted using the DELETE OBJECT statement and if you exit a block a code by using UNDO, RETURN without explicitly doing the DELETE OBJECT you will leak memory.
To solve this wrap the UNDO, RETURN inside of a DO block as follows:
DO:
DELETE OBJECT SomeDynamicBufferHandleGoesHere NO-ERROR.
UNDO, RETURN.
END.