Skip Menu |
Report information
Id: 123995
Status: resolved
Priority: 0/
Queue: perl5

Owner: Nobody
Requestors: brian.carpenter [at] gmail.com
Cc:
AdminCc:

Operating System: (no value)
PatchStatus: (no value)
Severity: low
Type: unknown
Perl Version: (no value)
Fixed In: 5.22.0



Subject: S_scan_heredoc: Assertion `shared' failed (toke.c:9284)
Built v5.21.10 (v5.21.9-73-gd98e5cd) with the following command line: ./Configure -des -Dusedevel -DDEBUGGING -Dcc=afl-gcc -Doptimize=-O2\ -g && AFL_HARDEN=1 make -j12 test-prep Bug found with AFL (http://lcamtuf.coredump.cx/afl) Valgrind: Use of bare << to mean <<"" is deprecated at test18-min line 1. perl: toke.c:9284: S_scan_heredoc: Assertion `shared' failed. Aborted GDB: gdb-peda$ file ~/perl/perl gdb-peda$ set args test18-min gdb-peda$ r [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". Use of bare << to mean <<"" is deprecated at test18-min line 1. perl: toke.c:9284: S_scan_heredoc: Assertion `shared' failed. Program received signal SIGABRT, Aborted. [----------------------------------registers-----------------------------------] RAX: 0x0 RBX: 0x7fffffffe63b --> 0x736574006c726570 ('perl') RCX: 0xffffffffffffffff RDX: 0x6 RSI: 0x111f RDI: 0x111f RBP: 0x7ffff6ea9a07 --> 0x257325732500203a (': ') RSP: 0x7fffffffd848 --> 0x7ffff6d923e0 (<*__GI_abort+384>: mov rdx,QWORD PTR fs:0x10) RIP: 0x7ffff6d8f165 (<*__GI_raise+53>: cmp rax,0xfffffffffffff000) R8 : 0x7ffff7fdd700 (0x00007ffff7fdd700) R9 : 0x6163735f53203a34 ('4: S_sca') R10: 0x8 R11: 0x202 R12: 0xef12e3 --> 0x4500646572616873 ('shared') R13: 0xefdd53 ("S_scan_heredoc") R14: 0x7ffff6ea9a07 --> 0x257325732500203a (': ') R15: 0x2444 ('D$') EFLAGS: 0x202 (carry parity adjust zero sign trap INTERRUPT direction overflow) [-------------------------------------code-------------------------------------] 0x7ffff6d8f15b <*__GI_raise+43>: movsxd rdi,eax 0x7ffff6d8f15e <*__GI_raise+46>: mov eax,0xea 0x7ffff6d8f163 <*__GI_raise+51>: syscall => 0x7ffff6d8f165 <*__GI_raise+53>: cmp rax,0xfffffffffffff000 0x7ffff6d8f16b <*__GI_raise+59>: ja 0x7ffff6d8f182 <*__GI_raise+82> 0x7ffff6d8f16d <*__GI_raise+61>: repz ret 0x7ffff6d8f16f <*__GI_raise+63>: nop 0x7ffff6d8f170 <*__GI_raise+64>: test eax,eax [------------------------------------stack-------------------------------------] 0000| 0x7fffffffd848 --> 0x7ffff6d923e0 (<*__GI_abort+384>: mov rdx,QWORD PTR fs:0x10) 0008| 0x7fffffffd850 --> 0xef12e3 --> 0x4500646572616873 ('shared') 0016| 0x7fffffffd858 --> 0x7ffff6eab9c1 --> 0x706c6568007325 ('%s') 0024| 0x7fffffffd860 --> 0x7fffffffd880 --> 0x3000000018 0032| 0x7fffffffd868 --> 0x2444 ('D$') 0040| 0x7fffffffd870 --> 0x7fffffffd970 --> 0x7fffffffe63b --> 0x736574006c726570 ('perl') 0048| 0x7fffffffd878 --> 0x7ffff6dc3fe6 (<__fxprintf+310>: lea rsp,[rbp-0x20]) 0056| 0x7fffffffd880 --> 0x3000000018 [------------------------------------------------------------------------------] Legend: code, data, rodata, value Stopped reason: SIGABRT 0x00007ffff6d8f165 in *__GI_raise (sig=<optimized out>) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64 64 ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory. Hexdump of 7-byte test case: 0000000 3b73 7b40 3c3c 003b 0000007 System Info: Debian 7, Kernel 3.2.65-1+deb7u1 x86_64, GCC 4.9.2, libc 2.13-38+deb7u7
Subject: test18-min
Download test18-min
application/octet-stream 7b

Message body not shown because it is not plain text.

RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 676b
I thought Father C had fixed this type of thing in [perl #123712] via commits e47d32dcd and d27f4b916c. It seems to fail only with ';' as the separator though: % ./miniperl -ce 's;@{<<;' Use of bare << to mean <<"" is deprecated at -e line 1. miniperl: toke.c:9284: S_scan_heredoc: Assertion `shared' failed. Aborted (core dumped) % ./miniperl -ce 's/@{<</' Substitution replacement not terminated at -e line 1. % ./miniperl -ce 's/@{<<//' Use of bare << to mean <<"" is deprecated at -e line 1. Can't find string terminator "" anywhere before EOF at -e line 1. % .. but IIRC we stick a fake ';' on the end of the input, so maybe it is interacting with that somehow. Hugo
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 852b
On Sat Mar 07 01:23:24 2015, hv wrote: Show quoted text
> I thought Father C had fixed this type of thing in [perl #123712] via > commits e47d32dcd and d27f4b916c. > > It seems to fail only with ';' as the separator though: > > % ./miniperl -ce 's;@{<<;' > Use of bare << to mean <<"" is deprecated at -e line 1. > miniperl: toke.c:9284: S_scan_heredoc: Assertion `shared' failed. > Aborted (core dumped) > % ./miniperl -ce 's/@{<</' > Substitution replacement not terminated at -e line 1. > % ./miniperl -ce 's/@{<<//' > Use of bare << to mean <<"" is deprecated at -e line 1. > Can't find string terminator "" anywhere before EOF at -e line 1. > % > > .. but IIRC we stick a fake ';' on the end of the input, so maybe it > is interacting with that somehow.
Yes. Your premonition was correct and helped me to fix the bug in b24768f02e. -- Father Chrysostomos
Download (untitled) / with headers
text/plain 200b
Thank you for submitting this ticket. The issue should now be resolved with the release today of Perl v5.22, which is available at http://www.perl.org/get.html -- Karl Williamson for the Perl 5 team


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

For issues related to this RT instance (aka "perlbug"), please contact perlbug-admin at perl.org