home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!zephyr.ens.tek.com!wrgate!fangorn.wr.tek.com!rogers
- From: rogers@fangorn.wr.tek.com (Roger Southwick)
- Newsgroups: comp.lang.perl
- Subject: "client" program (Camel book pg 338/339)
- Message-ID: <10616@wrgate.wr.tek.com>
- Date: 15 Sep 92 17:33:33 GMT
- Sender: news@wrgate.wr.tek.com
- Organization: Tektronix, Inc.
- Lines: 42
- X-Newsreader: Tin 1.1 PL5
-
- Hi fellow perl hacks....
-
- I'm fairly new to comp.lang.perl, and so if this subject has come up before,
- I apologize.... I've only been reading this newsgroup for 2 weeks.
-
- I've been playing with the "client" program on pg 338/339 of the Camel
- book and I've been unable to make it work. It bails out with the error:
-
- Invalid argument at ./tst line 38.
-
- Here's the snippet of code at that area:
-
- if(bind(S, $this)) {
- print "bind ok\n";
- }
- else {
- die $!; # <=== line 38.
- }
-
- My perl -v shows:
-
- $RCSfile: perl.c,v $$Revision: 4.0.1.7 $$Date: 92/06/08 14:50:39 $
- Patch level: 34
-
- I'm running this on a Sun 4, SunOS 4.1.2.
-
- I actually would like to know 2 things....
-
- 1) What is wrong with line 38 that 'die' can't print errno.
- I tried: die "$!"; # Same results.
- die "hello $!"; # This one prints "hello" before the error message.
-
- 2) Why the program gets to this point at all (i.e. why did the bind() fail).
-
- Any suggestions, pointers to ftp'able copies of Camel book perl sources
- which work on 4.1.[12], $10,000,000 in small unmarked bills, etc. would
- be appreciated.
-
- Thanks in advance....
- --
- -Roger (Roger.S.Southwick@tek.com)
- UUCP: ...!uunet!tektronix!Roger.S.Southwick
-