Ticket #1758 (closed bug: fixed)
Segfault caused by new dynop mapping code
| Reported by: | nwellnhof | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | core | Version: | 2.6.0 |
| Severity: | medium | Keywords: | |
| Cc: | Language: | ||
| Patch status: | Platform: |
Description
When working on TT #1746, I accidentally discovered another bug. The following script causes a segfault:
.loadlib 'perl6_ops'
.HLL "perl6"
.sub "" :load :init
load_language "perl6"
get_hll_global $P108, ["Perl6";"Module"], "Loader"
$P109 = "&infix:<,>"()
$P110 = "&circumfix:<{ }>"($P109)
set $S111, "$!storage"
getattribute $P112, $P110, $S111
$P108."need"("A", $P112)
.end
You must have Rakudo installed. The PIR code tries to load a non-existant module 'A.pm' and segfaults in the exception code.
The segfault happens here:
http://trac.parrot.org/parrot/browser/trunk/src/sub.c#L197
The op_info pointer is invalid because the area it points to has been reallocated here:
http://trac.parrot.org/parrot/browser/trunk/src/runcore/main.c#L417
It looks like this is caused by the new dynop mapping code.
Change History
Note: See
TracTickets for help on using
tickets.
