Your message dated Thu, 22 May 2008 14:24:17 +0300 with message-id <[EMAIL PROTECTED]> and subject line Re: Bug#379694: Snippet in perlthrtut causes Perl to die has caused the Debian Bug report #379694, regarding Snippet in perlthrtut causes Perl to die to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [EMAIL PROTECTED] immediately.) -- 379694: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=379694 Debian Bug Tracking System Contact [EMAIL PROTECTED] with problems
--- Begin Message ---Package: perl Version: 5.8.8-6 Severity: normal In the section "Queues: Passing Data Around" of perlthrtut, the following snippet of code is mentioned: use threads; use Thread::Queue; my $DataQueue = Thread::Queue->new; $thr = threads->new(sub { while ($DataElement = $DataQueue->dequeue) { print "Popped $DataElement off the queue\n"; } }); $DataQueue->enqueue(12); $DataQueue->enqueue("A", "B", "C"); $DataQueue->enqueue(\$thr); sleep 10; $DataQueue->enqueue(undef); $thr->join; I've saved this and run it as "foo.pl": $ perl foo.pl Invalid value for shared scalar at /usr/share/perl/5.8/Thread/Queue.pm line 90. A thread exited while 2 threads were running. Testing shows that it's the following line that's causing the error: $DataQueue->enqueue(\$thr); Commenting that line out causes the program to run fine. I don't know whether this is a documentation bug or a code bug. - Andrew Sayers -- System Information: Debian Release: testing/unstable APT prefers unstable APT policy: (500, 'unstable'), (500, 'testing') Architecture: i386 (i686) Shell: /bin/sh linked to /bin/bash Kernel: Linux 2.6.17-1-k7 Locale: LANG=en_GB, LC_CTYPE=en_GB (charmap=ISO-8859-1) Versions of packages perl depends on: ii libc6 2.3.6-15 GNU C Library: Shared libraries ii libdb4.4 4.4.20-6 Berkeley v4.4 Database Libraries [ ii libgdbm3 1.8.3-3 GNU dbm database routines (runtime ii perl-base 5.8.8-6 The Pathologically Eclectic Rubbis ii perl-modules 5.8.8-6 Core Perl modules Versions of packages perl recommends: ii perl-doc 5.8.8-6 Perl documentation -- no debconf information
--- End Message ---
--- Begin Message ---Version: 5.10.0-1 On Tue, Jul 25, 2006 at 03:57:43AM +0100, Andrew Sayers wrote: > Package: perl > Version: 5.8.8-6 > Severity: normal > > In the section "Queues: Passing Data Around" of perlthrtut, the > following snippet of code is mentioned: > I've saved this and run it as "foo.pl": > > $ perl foo.pl > Invalid value for shared scalar at /usr/share/perl/5.8/Thread/Queue.pm line > 90. > A thread exited while 2 threads were running. The example code was fixed by upstream change [ 31667] By: rgs on 2007/07/30 09:23:55 Log: Subject: Example in perlthrtut.pod doesn't work From: Elizabeth Mattijsen <[EMAIL PROTECTED]> Date: Mon, 30 Jul 2007 11:19:01 +0200 Message-Id: <[EMAIL PROTECTED]> Branch: perl ! pod/perlothrtut.pod pod/perlthrtut.pod http://www.nntp.perl.org/group/perl.perl5.porters/2007/07/msg127247.html The fix is in Perl 5.10.0, so I'm closing this bug. -- Niko Tyni [EMAIL PROTECTED]
--- End Message ---

