By following these simple steps you too can cause PAR to spin
into a tight infinite loop consuming most cpu time. I've been
able to reproduce this with 5.8.4 and 5.8.7. Jesse Vincent was
also able to reproduce this but I'm not sure what OS/Perl he 
was using. 

step 1: 
  pp -p -M DBI -e '1'

step 2: 
  create borkbork.pl
  use PAR './a.par';
  use DBI;
  print "Bork Bork!";

step 3: 
  perl borkbork.pl 


For giggles strace shows:

stat64("/tmp/mattwww_par_cache/f0b041f0.pm", {st_mode=S_IFREG|0644,
st_size=62063, ...}) = 0
stat64("/tmp/mattwww_par_cache/f0b041f0.pmc", 0xbfe404cc) = -1 ENOENT
(No such file or directory)
open("/tmp/mattwww_par_cache/f0b041f0.pm", O_RDONLY|O_LARGEFILE) = 3
ioctl(3, SNDCTL_TMR_TIMEBASE or TCGETS, 0xbfe402d8) = -1 ENOTTY
(Inappropriate ioctl for device)
_llseek(3, 0, [0], SEEK_CUR)            = 0
read(3, "#line 1 \"DBI.pm\"\n# $Id: DBI.pm,v"..., 4096) = 4096

here it reads the contents of DBI.pm aka f0b041f0.pm.

llseek(3, 62051, [62051], SEEK_SET)    = 0
_llseek(3, 0, [62051], SEEK_CUR)        = 0
close(3)                                = 0
brk(0x85b0000)                          = 0x85b0000
stat64("/tmp/mattwww_par_cache/f0b041f0.pm", {st_mode=S_IFREG|0644,
st_size=62063, ...}) = 0
stat64("/tmp/mattwww_par_cache/f0b041f0.pm", {st_mode=S_IFREG|0644,
st_size=62063, ...}) = 0

The stat64() calls are repeated until the end of time.



Reply via email to