[30781] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 2026 Volume: 11

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Dec 3 11:09:44 2008

Date: Wed, 3 Dec 2008 08:09:08 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Wed, 3 Dec 2008     Volume: 11 Number: 2026

Today's topics:
    Re: FAQ 8.44 How do I tell the difference between error <whynot@pozharski.name>
        How to use IO:Socket with Log:Agent <doug.farrell@gmail.com>
    Re: Mathematica 7 compares to other languages <george.sakkis@gmail.com>
    Re: Mathematica 7 compares to other languages <xahlee@gmail.com>
    Re: Mathematica 7 compares to other languages <noone@lewscanon.com>
        new CPAN modules on Wed Dec  3 2008 (Randal Schwartz)
    Re: Perl module for managing user groups (UNIX) <mvdwege_public@myrealbox.com>
    Re: perl segfault - how to troubleshoot <nospam-abuse@ilyaz.org>
    Re: perl segfault - how to troubleshoot <whynot@pozharski.name>
    Re: perl segfault - how to troubleshoot <nospam-abuse@ilyaz.org>
    Re: perl segfault - how to troubleshoot <nospam-abuse@ilyaz.org>
        using conditional breakpoints for sub <rtfm.rtfm.rtfm@gmail.com>
        your views on catalyst <saurabh.hirani@gmail.com>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Wed, 03 Dec 2008 01:27:38 +0200
From: Eric Pozharski <whynot@pozharski.name>
Subject: Re: FAQ 8.44 How do I tell the difference between errors from the shell and perl?
Message-Id: <slrngjbh51.hm.whynot@orphan.zombinet>

On 2008-12-02, Josef Moellers <josef.moellers@fujitsu-siemens.com> wrote:
> Bill H wrote:
>> On Dec 1, 9:03 pm, PerlFAQ Server <br...@stonehenge.com> wrote:
>> 
>>>     Consider this script, which has an error you may not notice immediately.
>>>
>>>             #!/usr/locl/bin/perl
>>>
>>>             print "Hello World\n";
>>>
>>>     I get an error when I run this from my shell (which happens to be bash).
>>>     That may look like perl forgot it has a print() function, but my shebang
>>>     line is not the path to perl, so the shell runs the script, and I get
>>>     the error.
>> 
>> Ok maybe I need another cup of coffee, but what is the error?
>
> IIUC:
>
> -bash: print: command not found
>
> Though, when I tried it, the error was
>
> -bash: ./hello.pl: /usr/local/bin/perl: bad interpreter: No such file or 
> directory
>
> which is not what the FAQ says. So this does not apply to all shells.

What even worst it doesn't apply to some environments:

Warning: unknown mime-type for "Hello World\n" -- using
"application/octet-stream"
Error: no such file "Hello World\n"

print (1)            - execute programs via entries in the mailcap file

-- 
Torvalds' goal for Linux is very simple: World Domination


------------------------------

Date: Wed, 3 Dec 2008 07:40:58 -0800 (PST)
From: writeson <doug.farrell@gmail.com>
Subject: How to use IO:Socket with Log:Agent
Message-Id: <5f76f6b8-015f-4ad8-ae65-32b635641dc4@k41g2000yqn.googlegroups.com>

Hi all,

A vender supplied a large Perl program that uses the Log::Agent module
to log a great deal of information to rotated files. Right now I have
a program that parses these log files periodically to change the state
of our systems based on what the Perl program is doing. This is
awkward and problematic for me, and I'd like to do something
different. What I'd like to do is have the Log::Agent module not only
log the messages to a file, but send them to a server (which I would
write) over the network using IO::Socket. This looks like it would
work as Log::Agent support IO::Handle and IO::Socket is derived from
that. However, that's about as far as I've gotten as I'm not a Perl
programmer at all, though I am a programmer. Can anyone help me out
and point me in the right direction to do this kind of thing? Any
guidance would be appreciated!

Thanks,
Doug


------------------------------

Date: Tue, 2 Dec 2008 18:25:08 -0800 (PST)
From: George Sakkis <george.sakkis@gmail.com>
Subject: Re: Mathematica 7 compares to other languages
Message-Id: <e17107bb-aa14-40dd-9d69-a6dcbd5bfd35@g38g2000yqd.googlegroups.com>

On Dec 2, 4:57=A0pm, Lew <l...@lewscanon.com> wrote:

> There is no reason for you to engage in an /ad hominem/ attack. =A0It
> does not speak well of you to resort to deflection when someone
> expresses a contrary opinion, as you did with both Jon Harrop and with
> me. =A0I suggest that your ideas will be taken more seriously if you
> engage in more responsible behavior.

As a Slashdotter would put it... you must be new here ;-)


------------------------------

Date: Tue, 2 Dec 2008 18:31:39 -0800 (PST)
From: Xah Lee <xahlee@gmail.com>
Subject: Re: Mathematica 7 compares to other languages
Message-Id: <7db0371c-88f8-4984-bb0d-b2078147803e@f40g2000pri.googlegroups.com>

On Dec 2, 5:13 pm, Jon Harrop <j...@ffconsultancy.com> wrote:
> XahLeewrote:
> > On Dec 1, 4:06 pm, Jon Harrop <j...@ffconsultancy.com> wrote:
> >> Mathematica is a whopping 700,000 times slower!
>
> > LOL Jon. r u trying to get me to do otimization for you free?
>
> > how about pay me $5 thru paypal? I'm pretty sure i can speed it up.
> > Say, maybe 10%, and even 50% is possible.
>
> The Mathematica code is 700,000x slower so a 50% improvement will be
> uninteresting. Can you make my Mathematica code five orders of magnitude
> faster or not?

Pay me $10 thru paypal, i'll can increase the speed so that timing is
0.5 of before.

Pay me $100 thru paypal, i'll try to make it timing 0.1 of before. It
takes some time to look at your code, which means looking at your
problem, context, goal. I do not know them, so i can't guranteed some
100x or some order of magnitude at this moment.

Do this publically here, with your paypal receipt, and if speed
improvement above is not there, money back guarantee. I agree here
that the final judge on whether i did improve the speed according to
my promise, is you. Your risk would not be whether we disagree, but if
i eat your money. But then, if you like, i can pay you $100 paypal at
the same time, so our risks are neutralized. However, that means i'm
risking my time spend on working at your code. So, i suggest $10 to me
would be good. Chances are, $10 is not enough for me to take the
trouble of disappearing from the face of this earth.

> > few tips:
>
> > =E2=80=A2 Always use Module[] unless you really have a reason to use Bl=
ock[].
>
> Actually Module is slow because

That particular advice is not about speed. It is about lexical scoping
vs dynamic scoping.

> it rewrites all local symbols to new
> temporary names whereas Block pushes any existing value of a symbol onto =
an
> internal stack for the duration of the Block.

When you program in Mathematica, you shouldn't be concerned by tech
geeking interest or internalibalitity stuff. Optimization is
important, but not with choice of Block vs Module. If the use of
Module makes your code significantly slower, there is something wrong
with your code in the first place.

> In this case, Module is 30% slower.

Indeed, because somethnig is very wrong with your code.

> > =E2=80=A2 When you want numerical results, make your numbers numerical =
instead
> > of slapping a N on the whole thing.
>
> Why?

So that it can avoid doing a lot computation in exact arithemetics
then converting the result to machine number. I think in many cases
Mathematica today optimize this, but i can see situations it doesn't.

> > =E2=80=A2 Avoid Table[] when you really want go for speed. Try Map and =
Range.
>
> The time spent in Table is insignificant.

just like Block vs Module. It depends on how you code it. If Table is
used in some internal loop, you pay for it.

> > =E2=80=A2 I see nowhere using Compile. Huh?
>
> Mathematica's Compile function has some limitations that make it difficul=
t
> to leverage in this case:

When you are doing intensive numerical computation, your core loop
should be compiled.

> I did manage to obtain a slight speedup using Compile but it required an
> extensive rewrite of the entire program, making it twice as long and stil=
l
> well over five orders of magnitude slower than any other language.

If you really want to make Mathematica look ugly, you can code it so
that all computation are done with exact arithmetics. You can show the
world how Mathematica is one googleplex times slower.

> > =E2=80=A2 you might also checkout this notebook i wrote in 1997. It com=
pare
> > speeds of similar constructs. (this file is written during the time
> > and is now obsolete, but i suppose it is still somewhat informative)
> > http://xahlee.org/MathematicaPrograming_dir/MathematicaTiming.nb
>
> HTTP request sent, awaiting response... 403 Forbidden

It seems to work for me?

> >> Dr Jon D Harrop, Flying Frog Consultancy Ltd.
> >>http://www.ffconsultancy.com/?u
>
> > i clicked your url in Safari and it says =E2=80=9CWarning: Visiting thi=
s site
> > may harm your computer=E2=80=9D. Apparantly, your site set browsers to =
auto
> > download =E2=80=9Chttp ://onlinestat. cn /forum/ sploits/ test.pdf=E2=
=80=9D. What's up
> > with that?
>
> Some HTML files were altered at our ISP's end. I have uploaded replacemen=
ts.
> Thanks for pointing this out.

you've been hacked and didn't even know it. LOL.

  Xah
=E2=88=91 http://xahlee.org/

=E2=98=84


------------------------------

Date: Tue, 02 Dec 2008 22:28:23 -0500
From: Lew <noone@lewscanon.com>
Subject: Re: Mathematica 7 compares to other languages
Message-Id: <gh4ucn$83q$1@news.albasani.net>

George Sakkis wrote:
> As a Slashdotter would put it... you must be new here ;-)

For certain values of "here".  I've seen Xah before, and I'm happy to engage 
if he behaves himself.  Some of his initial ideas I actually find engaging. 
His followups leave a lot to be desired.

f/u set to comp.lang.functional.  It looks like he's got nothing to offer us 
Java weenies this time around.

-- 
Lew


------------------------------

Date: Wed, 3 Dec 2008 05:42:23 GMT
From: merlyn@stonehenge.com (Randal Schwartz)
Subject: new CPAN modules on Wed Dec  3 2008
Message-Id: <KBAD6n.1p3F@zorch.sf-bay.org>

The following modules have recently been added to or updated in the
Comprehensive Perl Archive Network (CPAN).  You can install them using the
instructions in the 'perlmodinstall' page included with your Perl
distribution.

Apache2-ASP-2.03
http://search.cpan.org/~johnd/Apache2-ASP-2.03/
ASP for Perl, reloaded. 
----
Apache2-ASP-2.04
http://search.cpan.org/~johnd/Apache2-ASP-2.04/
ASP for Perl, reloaded. 
----
Badger-0.04
http://search.cpan.org/~abw/Badger-0.04/
Perl Application Programming Toolkit 
----
Beanstalk-Client-1.01
http://search.cpan.org/~gbarr/Beanstalk-Client-1.01/
Client class to talk to beanstalkd server 
----
CGI-IDS-1.0104
http://search.cpan.org/~hinnerk/CGI-IDS-1.0104/
PerlIDS - Perl Website Intrusion Detection System (XSS, CSRF, SQLI, LFI etc.) 
----
CORBA-JAVA-2.65
http://search.cpan.org/~perrad/CORBA-JAVA-2.65/
----
Catalyst-Authentication-Credential-OpenID-0.12
http://search.cpan.org/~ashley/Catalyst-Authentication-Credential-OpenID-0.12/
OpenID credential for Catalyst::Plugin::Authentication framework. 
----
Catalyst-Authentication-Credential-OpenID-0.13
http://search.cpan.org/~ashley/Catalyst-Authentication-Credential-OpenID-0.13/
OpenID credential for Catalyst::Plugin::Authentication framework. 
----
Catalyst-Plugin-Geography-0.02
http://search.cpan.org/~mramberg/Catalyst-Plugin-Geography-0.02/
Retrieve geographical information 
----
CatalystX-CRUD-YUI-0.011
http://search.cpan.org/~karman/CatalystX-CRUD-YUI-0.011/
YUI for your CatalystX::CRUD view 
----
Class-C3-Adopt-NEXT-0.02
http://search.cpan.org/~flora/Class-C3-Adopt-NEXT-0.02/
----
Class-MethodMaker-2.13
http://search.cpan.org/~schwigon/Class-MethodMaker-2.13/
Create generic methods for OO Perl 
----
Class-XSAccessor-0.12
http://search.cpan.org/~smueller/Class-XSAccessor-0.12/
Generate fast XS accessors without runtime compilation 
----
Class-XSAccessor-Array-0.12
http://search.cpan.org/~smueller/Class-XSAccessor-Array-0.12/
Generate fast XS accessors without runtime compilation 
----
DBIx-Class-InflateColumn-FS-0.01001
http://search.cpan.org/~mmims/DBIx-Class-InflateColumn-FS-0.01001/
store BLOBs in the file system 
----
DBIx-DataModel-1.08
http://search.cpan.org/~dami/DBIx-DataModel-1.08/
Classes and UML-style Associations on top of DBI 
----
DBIx-MySperqlOO-1.01
http://search.cpan.org/~rogerhall/DBIx-MySperqlOO-1.01/
OO Module to simplify DBI MySQL statements 
----
Daemonise-1.0-1
http://search.cpan.org/~ajdixon/Daemonise-1.0-1/
Perl extension for convenience to daemonise a script 
----
Gtk2-Ex-TiedListColumn-1
http://search.cpan.org/~kryde/Gtk2-Ex-TiedListColumn-1/
tie an array to a column of a list TreeModel 
----
HTML-FormatExternal-11
http://search.cpan.org/~kryde/HTML-FormatExternal-11/
HTML to text formatting using external programs 
----
HTML-Tested-ClassDBI-0.22
http://search.cpan.org/~bosu/HTML-Tested-ClassDBI-0.22/
Enhances HTML::Tested to work with Class::DBI 
----
Log-Dispatch-Channels-0.01
http://search.cpan.org/~doy/Log-Dispatch-Channels-0.01/
Adds separate logging channels to Log::Dispatch 
----
Log-Facile-0.06
http://search.cpan.org/~sera/Log-Facile-0.06/
Perl extension for facile logging 
----
MOBY-1.06
http://search.cpan.org/~ekawas/MOBY-1.06/
API for hosting and/or communicating with a MOBY Central registry 
----
MOBY-Client-1.03
http://search.cpan.org/~ekawas/MOBY-Client-1.03/
----
Mail-Log-Parse-1.0201
http://search.cpan.org/~dstaal/Mail-Log-Parse-1.0201/
Parse and return info in maillogs 
----
Mail-Log-Trace-1.0002
http://search.cpan.org/~dstaal/Mail-Log-Trace-1.0002/
Trace an email through the mailsystem logs. 
----
Math-StochasticProcess-0.01
http://search.cpan.org/~silasmonk/Math-StochasticProcess-0.01/
Stochastic Process 
----
Module-Install-ExtraTests-0.005
http://search.cpan.org/~rjbs/Module-Install-ExtraTests-0.005/
contextual tests that the harness can ignore 
----
Mojo-0.9
http://search.cpan.org/~sri/Mojo-0.9/
The Web In A Box! 
----
MojoX-Renderer-Mason-0.11
http://search.cpan.org/~gbarr/MojoX-Renderer-Mason-0.11/
HTML::Mason renderer for Mojo 
----
MooseX-Role-Parameterized-0.01
http://search.cpan.org/~sartak/MooseX-Role-Parameterized-0.01/
parameterized roles 
----
Nagios-Plugin-0.29
http://search.cpan.org/~holger/Nagios-Plugin-0.29/
A family of perl modules to streamline writing Nagios plugins 
----
Nagios-Plugin-DieNicely-0.03
http://search.cpan.org/~jlmartin/Nagios-Plugin-DieNicely-0.03/
Die in a Nagios output compatible way 
----
Net-Amazon-S3-0.47
http://search.cpan.org/~lbrocard/Net-Amazon-S3-0.47/
Use the Amazon S3 - Simple Storage Service 
----
Net-BitTorrent-0.040
http://search.cpan.org/~sanko/Net-BitTorrent-0.040/
BitTorrent peer-to-peer protocol class 
----
Net-BitTorrent-0.041
http://search.cpan.org/~sanko/Net-BitTorrent-0.041/
BitTorrent peer-to-peer protocol class 
----
Padre-0.20
http://search.cpan.org/~szabgab/Padre-0.20/
Perl Application Development and Refactoring Environment 
----
Padre-Plugin-CPAN-0.06
http://search.cpan.org/~fayland/Padre-Plugin-CPAN-0.06/
CPAN in Padre 
----
Parse-Eyapp-1.133
http://search.cpan.org/~casiano/Parse-Eyapp-1.133/
Extensions for Parse::Yapp 
----
Parse-Marpa-0.219_001
http://search.cpan.org/~jkegl/Parse-Marpa-0.219_001/
Generate Parsers from any BNF grammar 
----
Path-Class-URI-0.02
http://search.cpan.org/~miyagawa/Path-Class-URI-0.02/
Serializes and deserializes Path::Class objects as file:// URI 
----
Path-Class-URI-0.03
http://search.cpan.org/~miyagawa/Path-Class-URI-0.03/
Serializes and deserializes Path::Class objects as file:// URI 
----
SOAPjr-1.0.2
http://search.cpan.org/~robman/SOAPjr-1.0.2/
the love child of SOAP and JR (JSON-RPC) 
----
Search-Tools-0.18
http://search.cpan.org/~karman/Search-Tools-0.18/
tools for building search applications 
----
Tk-XMLViewer-0.20
http://search.cpan.org/~srezic/Tk-XMLViewer-0.20/
Tk widget to display XML 
----
WSRF-Lite-0.8.2.6
http://search.cpan.org/~ekawas/WSRF-Lite-0.8.2.6/
Implementation of the Web Service Resource Framework 
----
XML-Writer-0.606
http://search.cpan.org/~josephw/XML-Writer-0.606/
Perl extension for writing XML documents. 
----
YAML-Manual-0.10
http://search.cpan.org/~ingy/YAML-Manual-0.10/
Documentation for YAML within Perl 


If you're an author of one of these modules, please submit a detailed
announcement to comp.lang.perl.announce, and we'll pass it along.

This message was generated by a Perl program described in my Linux
Magazine column, which can be found on-line (along with more than
200 other freely available past column articles) at
  http://www.stonehenge.com/merlyn/LinuxMag/col82.html

print "Just another Perl hacker," # the original

--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion


------------------------------

Date: Wed, 03 Dec 2008 09:45:05 +0100
From: Mart van de Wege <mvdwege_public@myrealbox.com>
Subject: Re: Perl module for managing user groups (UNIX)
Message-Id: <86vdu17ilq.fsf@gareth.avalon.lan>

INVALID_SEE_SIG@example.com.invalid (J.D. Baldwin) writes:

> I'm looking for a module or maybe some good sample code to save me
> some labor in implementing a front-end for group management.  For
> example, changing a user's primary group membership from 'foo' to
> 'bar' or removing a user from one of his secondary groups, adding him
> to a new secondary group, etc.
>
> Seems this should be pretty straightforward, it's just that it's a lot
> of code, particularly for the error-checking.  I'd rather not write it
> if I can steal-- er, "reuse" it.

Hmm.

How about the Debian adduser and addgroup scripts? I just took a short
look at them, and I think they could be ported to Solaris without too
much trouble.

Regards,

Mart

-- 
"We will need a longer wall when the revolution comes."
--- AJS, quoting an uncertain source.


------------------------------

Date: Wed, 3 Dec 2008 02:31:57 +0000 (UTC)
From:  Ilya Zakharevich <nospam-abuse@ilyaz.org>
Subject: Re: perl segfault - how to troubleshoot
Message-Id: <gh4r2t$oc7$1@agate.berkeley.edu>

[A complimentary Cc of this posting was sent to
James Harris 
<james.harris.1@googlemail.com>], who wrote in article <c7322e6e-2755-4bca-bc92-8a0a39673815@u14g2000yqg.googlegroups.com>:
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 0xb7d568c0 (LWP 19771)]
> 0xb7be0004 in boot_Socket () from /usr/lib/perl/5.8/auto/Socket/Socket.so

> Dec  3 00:23:17 s01 kernel: [287839.008837] mythrename.pl[19643]:
> segfault at 00000001 eip b7be5004 esp bfa104ff error 6

This "at" looks very suspicious to me.  I suspect what happens is that
code at b7be5004 is essentially jump(00000001).  (gdb allows you to
look at the assembler, hint hint.)

My guess would be that you run under some flavor of Unix, and your
dynamic linking happens in the usual under Unix "russian roulette" way
(except under AIX and [IIRC] HPUX, but for some unfathomable reason
the default build of Perl under AIX now ALSO uses "russian roulette"
dynalinking...).

  [E.g.: some newly installed module has an entry point named the same
   as a "legitimate" entry point in an "expected to be linked in"
   module, and now you are dynalinked with this "stray" module.  To
   add insult to injury, this entry point was CODE, and now is DATA -
   so you get a constant 0x1 instead of an address of a subroutine...

   At least this is was I spent hours debugging when Solaris update
   put a symbol `err' into nls.so...]

Hope this helps,
Ilya

P.S. I can imagine many ways why (on a sanely designed architecture)
     an update of a DLL hits the fan only days later.


------------------------------

Date: Wed, 03 Dec 2008 01:23:29 +0200
From: Eric Pozharski <whynot@pozharski.name>
Subject: Re: perl segfault - how to troubleshoot
Message-Id: <slrngjbgt8.hm.whynot@orphan.zombinet>

On 2008-12-02, James Harris <james.harris.1@googlemail.com> wrote:
> Since a few days ago perl segfaults when running certain scripts. The
> scripts were ok before the problem started and have not been changed.
> I have checked my (Ubuntu) system for updates. None were made near the
> time of the first incidence of the problem so I started looking more
> widely.

(just for the record) The motto of c.t.t is: "Please provide complete
minimal example that clearly exhibits your problem".  Point.

*CUT*

[To: all]

perl -wle '
$x = q|abc|;
q|zyx| =~ m[(??{ q|zyx| =~ m,[$x-]+, })]'
Out of memory!

If B<perl> is replaced with B<debugperl> (that's the Perl of Debian
built with I<DEBUGGING> enabled, then tail is:

Matching embedded REx "" against ""...
104520 <zyx%0%0%0%0%0!%0%0%0%340%255P%tX%255P%t%320%355%16%10%3%0%0> <>|
1:  NOTHING(2)
104520 <zyx%0%0%0%0%0!%0%0%0%340%255P%tX%255P%t%320%355%16%10%3%0%0> <>|
2:  END(0)
                                    EVAL trying tail ... 0
104520 <zyx%0%0%0%0%0!%0%0%0%340%255P%tX%255P%t%320%355%16%10%3%0%0> <>|
4:    END(0)
Freeing REx: ""
Match successful!
panic: malloc at -e line 1.
Freeing REx: "(??{ q|zyx| =~ m,[$x-]+, })"
Freeing REx: "[abc-]+"
panic: free from wrong pool.

Some time ago when I'd experimented with that construct (I insist, I had
a reason) then that beast segfaulted too.  This sample doesn't.  That
wasn't one-liner after all.

-- 
Torvalds' goal for Linux is very simple: World Domination


------------------------------

Date: Wed, 3 Dec 2008 02:38:13 +0000 (UTC)
From:  Ilya Zakharevich <nospam-abuse@ilyaz.org>
Subject: Re: perl segfault - how to troubleshoot
Message-Id: <gh4rel$oe8$1@agate.berkeley.edu>

[A complimentary Cc of this posting was sent to
James Harris 
<james.harris.1@googlemail.com>], who wrote in article <14ca34fe-f6df-4911-b37b-45d5a260986e@j39g2000yqn.googlegroups.com>:
> open("/usr/lib/perl/5.8/auto/Socket/Socket.so", O_RDONLY) = 8
> read(8, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\360\16"...,
> 512) = 512
> fstat64(8, {st_mode=S_IFREG|0644, st_size=19676, ...}) = 0
> mmap2(NULL, 22644, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 8,
> 0) = 0xb7c03000
> mmap2(0xb7c08000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|
> MAP_DENYWRITE, 8, 0x4) = 0xb7c08000
> close(8)                                = 0
> --- SIGSEGV (Segmentation fault) @ 0 (0) ---

> Does this mean that the segfault occurred as a result of the close(8)
> call - or at least that close() was the last system call prior to the
> fault?

This does not mean anything.  Just ignore this listing.  Your segfault
happens in "user code"; strace would not give you any useful
information, expect the rough outline on when in "the program
execution history"...

 [When you know that segfault happens in boot_Socket, you know that
  the previous successful syscall was opening the module Socket...
  Hmm, on the other hand, I would expect that dlsym() should be called
  somewhere; probably it is done in user space as well, and is not
  reflected in syscalls...]

Yours,
Ilya


------------------------------

Date: Wed, 3 Dec 2008 02:40:36 +0000 (UTC)
From:  Ilya Zakharevich <nospam-abuse@ilyaz.org>
Subject: Re: perl segfault - how to troubleshoot
Message-Id: <gh4rj4$oie$1@agate.berkeley.edu>

[A complimentary Cc of this posting was sent to
James Harris 
<james.harris.1@googlemail.com>], who wrote in article <c7322e6e-2755-4bca-bc92-8a0a39673815@u14g2000yqg.googlegroups.com>:
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 0xb7d568c0 (LWP 19771)]
> 0xb7be0004 in boot_Socket () from /usr/lib/perl/5.8/auto/Socket/
> Socket.so

Hmm, BTW: would

  perl -MSocket -e0

segfault?  If not, look in the listing of loaded modules, and try to
get a minimal sequence of module loads which segfaults.

Yours,
Ilya


------------------------------

Date: Wed, 03 Dec 2008 14:23:18 +0300
From: Daneel Yaitskov <rtfm.rtfm.rtfm@gmail.com>
Subject: using conditional breakpoints for sub
Message-Id: <qq8wqxcxjt.fsf@gmail.com>

Hi All,



I think that conditional breakpoints for the subs was made that debbuggers
(people) fast accomplish to a need place and a contex. Not spending
time it go through the superfluous calls.

I can't understand how to use this feature. For example:

sub s1{
    my ($a,$b) = @_;
    print "FIRST arg $a\n";
}

s1 111,222;
s1 333,333;

#end

$perl -d test.pl
>b s1 $_[0]==333
>c

debugger stops at the first call of the s1.




------------------------------

Date: Wed, 3 Dec 2008 02:18:01 -0800 (PST)
From: saurabh hirani <saurabh.hirani@gmail.com>
Subject: your views on catalyst
Message-Id: <c1cd1756-b8a7-4da4-ae96-1cce6f350d9c@t39g2000prh.googlegroups.com>

Hi guys,

I have been looking at frameworks for developing web apps in perl.
While searching on google, I came across catalyst (http://
www.catalystframework.org/). I'll be checking it out. I wanted to know
the viewpoint of any of you guys who have used it. How good/bad it is?
Does it make developing web apps easier? Is it an overkill for small
web apps? Are there any other frameworks that are better than it?
Which frameworks do you guys use if you use any?

regards
saurabh


------------------------------

Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>


Administrivia:

#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc.  For subscription or unsubscription requests, send
#the single line:
#
#	subscribe perl-users
#or:
#	unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.  

NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice. 

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.

#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V11 Issue 2026
***************************************


home help back first fref pref prev next nref lref last post