Consultor Eletrônico



Kbase P122978: Error 49 setting the VISIBLE attribute to TRUE for a frame. crdirRestore() in the stack trace.
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   16/10/2008
Status: Unverified

FACT(s) (Environment):

Progress 9.1E
OpenEdge 10.1A
OpenEdge 10.1B

SYMPTOM(s):

Error 49 running a ABL procedure:

SYSTEM ERROR: Memory violation. (49)

Stack trace from _progres reads:

crdirRestore
crEstblshCntxt
umxEvalFrm
umFrmRealize

ABL session crashes.

Crash occurs while setting the VISIBLE attribute of a widget-handle to TRUE.

The widget-handle points a static frame.

The program that defines the frame is no longer in the call stack.

CAUSE:

This is a known issue.

When viewing a frame, the AVM evaluates all expressions in the WITH phrase of said frame. That happens too when re-viewing the frame after it has been hidden (as is the case when setting its VISIBLE attribute to TRUE).
For this operation to be carried out, it's necessary that the .r code of the procedure where the frame is defined, is still available in memory.

In this particular case, though, the ABL is setting the VISIBLE attribute to TRUE for a static frame whose defining procedure is no longer in the call stack (that is, it's no longer active). Depending on the memory usage of the application, the AVM may decide to re-use the memory that was once allocated for said .r code.

When that happens, setting the VISIBLE attribute to TRUE will cause the AVM to reference memory whose original content has been lost, and a crash with the given stack trace will occur.

FIX:

Do not set the VISIBLE attribute to TRUE for a static frame whose defining procedure is not longer in the call stack.

Alternatively, define the static frame in a persistent procedure, and delete the persistent procedure only when you are sure that the static frame defined therein, will no longer be referenced.
Upgrade to 10.1B01 or later release where the crash issue has been fixed.