Memory not cleaned (with Struct)

Hi,

in a customization job, I make use of 2 different Arrays of Struct, like

/*code snippet

Array = new Array(types::Class);

Array2 = new Array(types::Class);

Array.value(id, new Struct(types::real, "param1", types::Integer, "param2"));

Array2.value(id, new Struct(types::string, "param3", types::Integer, "param4"));

*/

first array holds in real 23 values in the struct (23 seems to be the limit in Struct)

So thats why I created a 2nd Array, cause I have more values.

What I experience is that after making a modification and start the code again, some values of the Struct are old values.

It looks like the Structs are not fully cleaned or initialized in memory.

Is this a memory leak?

Is finalize() the way to fix this, if yes how to use finalize exactly?

What can be the problem of this behaviour?

Thanks

Related
Recommended