in reply to Re^2: Lite.pm Causing Problems
in thread Lite.pm Causing Problems

Using undef will merely move the error from the end of the output to the middle of the output. The DESTROY method will be called at some time, and the only solution is to ensure that the object is valid when it is called.

A small addition: if the corruption is occurring due to the undefined order in which global destruction is carried out, releasing the last reference prior to global destruction will resolve the problem. But you do not know that that is the case — there could be a bug in the questioner's program that is corrupting the object or global destruction may be trashing it before destroying Win32::OLE::Lite. You. Do. Not. Know. Which. Is. Happening. Here.

Replies are listed 'Best First'.
Re^4: Lite.pm Causing Problems
by Anonymous Monk on Sep 06, 2019 at 04:20 UTC

    At the end of the output you can't do nothing about it :) in the middle you can

      What? If anything it is easier to chop off of the end by adding an end marker to the intended output and using sed to remove anything after that marker. Oh wait, our questioner is using Windows and therefore probably does not have sed installed.

      And why did writing this feel like answering Insane Troll Logic?

      A reply falls below the community's threshold of quality. You may see it by logging in.