Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^2: whats wrong? it gives me many error

by linuxer (Curate)
on Sep 16, 2014 at 18:53 UTC ( #1100813=note: print w/replies, xml ) Need Help??


in reply to Re: whats wrong? it gives me many error
in thread whats wrong? it gives me many error

my ($host, $port, $request, $proto) = ('tcp');

But that assigns 'tcp' to $host. Shouldn't it be assigned to $proto?

So, maybe one of these:

my ($host, $port, $request, $proto) = ( undef, undef, undef, 'tcp' ); # or my ($host, $port, $request, $proto) = ( '', '', '', 'tcp' ); # or my ($host, $port, $request, $proto); $proto = 'tcp';

Replies are listed 'Best First'.
Re^3: whats wrong? it gives me many error
by LanX (Archbishop) on Sep 16, 2014 at 19:59 UTC
    > my ($host, $port, $request, $proto) = ('tcp');

     my ($proto, $host, $port, $request) = ('tcp');

    But ikegami already showed this on SO... :)

    Cheers Rolf

    (addicted to the Perl Programming Language and ☆☆☆☆ :)

Re^3: whats wrong? it gives me many error
by blue_cowdawg (Monsignor) on Sep 16, 2014 at 19:25 UTC

    Personally I'd go with the latter.


    Peter L. Berghold -- Unix Professional
    Peter -at- Berghold -dot- Net; Blog: http://blog.berghold.net Warning: No political correctness allowed.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1100813]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (6)
As of 2020-05-29 20:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If programming languages were movie genres, Perl would be:















    Results (171 votes). Check out past polls.

    Notices?