[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: passes syntax but xchat crashes



Your code below barely resembles perl code...

The best help I can offer is for you to purchase the following book:

http://www.oreilly.com/catalog/lperl2/

If that's not possible/practical... then you'd do yourself a serious favor by
reading the man pages that come with perl.  (man perl or perldoc perl).  Perl
is a great language and fun to code in.  But one must learn to code properly
first. :)

Mike


"D. Hoyem" wrote:
> 
> Hi all,
>   First off I'm a newbie with perl and what I'm trying
> to do is write a perl script for xchat that will play
> popups like mIRC and Pirch does with a nick in them.
> The space for the nick is 9 characters long and this
> is a portion of the script that I've done.  If I do
> the perl -c myscript.pl it passes with out any syntax
> errors, but as soon as I try and run it, xchat
> shutsdown.  I think that my error is in the "
> '$nick'    "); area but could ue some comments/help
> 
> sub talk_handler {
>   $msg = shift(@_);
>   $nick = $msg;
>   if (length ($nick) > 9) {
>         then (length ($nick) eq "'$nick'");}
> elsif (length ($nick) == 0) {
>         then (length ($nick) eq "    '$nick'     ");}
> elsif (length ($nick) == 1) {
>         then (length ($nick) eq "    '$nick'    ");}
> elsif (length ($nick) == 2) {
>         then (length ($nick) eq "   '$nick'    ");}
> etc.
> Thanks in advance for your help.
> Don


-- 
Mike Guidero [KD7ILU] - Genius in disguise.
*** Real programmers practice safe HEX. ***
PGP Public Key: (Unavailable at this time)
Fingerprint   : DD87 C663 1767 B11F  1EDE D2AA 0DD1 89C6  56D7 109A
-
XChat-discuss: mailing list for XChat users
Archive:       http://mail.nl.linux.org/lists/
Posted By:     Mike Guidero <kymermosst@penguinpowered.com>