I get a crash in perl with the following stack trace:

#10 0x5555a3ba in mspace_free ()
#11 0x5555c628 in free ()
#12 0x087bfd48 in Perl_sv_clear ()
#13 0x087d2a06 in do_clean_all ()
#14 0x087ba0fc in Perl_sv_clean_all ()
#15 0x0874b198 in perl_destruct ()

The perl_destruct is called explicitly by my software, to release all memory used by perl.
I think it is related to some bug in my perl script or some wrong coding style.
The perl scripts are big (several thousand lines), so it is not possible for me to find that point easily.
Please tell if you have encountered similar problems or possible reasons.
Perl Version -> perl, v5.8.3 built for i686-linux-thread-multi
Platform -> Linux 32bit
Environment -> perl_module, called from C/C++, and perl_destruct also called from C.

The issue is reproducible only on a testcase, not available at our end.<\br> So can not take the approach of shortening the script and re-running the test-case again.


Thanks

In reply to Crash in perl_destruct by rahulgupta70

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.