Re: "my_sys_socket.ph did not r

Roy T. Fielding (fielding@avron.ICS.UCI.EDU)
Sat, 17 Sep 1994 01:27:42 -0700


> I then used both Jack's and Roy's "socket fixer" programs. Jack's fixer
> (socket-fixer.pl) returns the following output:
> 
> sub AF_INET {2};
> sub PF_INET {2};
> sub SOCK_DGRAM {2};
> sub SOCK_STREAM {1};
> 
> Roy's (socket-fixer.c) does this:
> 
> sub AF_INET { 2; }
> sub PF_INET { 2; }
> sub SOCK_DGRAM { 2; }
> sub SOCK_STREAM { 1; }
> 
> First of all, why are they different, and does it matter?

Because Jack's program has two bugs, and mine only has one (;-)

> Originally, after copying Roy's output to "my_sys_socket.ph" and replacing the
> reqire call to "sys/socket.ph" with "my_sys_socket.ph" I got an error from
> "get" telling my that my_sys_socket.ph did not return a value.
> 
> In my finite wisdom, I edited my_sys_socket.ph like this:
> 
> sub AF_INET { 2; }
> sub PF_INET { 2; }
> sub SOCK_DGRAM { 2; }
> sub SOCK_STREAM { 1; }
> 1;
> 
> Tricky, huh?

Very clever -- that was the bug in my version.

> In any event, this doesn't work either. I still get "connection refused".

*sigh* May I suggest strangling the person who bought the OSF/2 machine?

Interestingly, that is the same output as I get for SunOS 4.1.2 (a BSD system).
I could have sworn that OSF is supposed to be different.  Hmmmmmm.....
let me find that book..... nope, nothing useful there.

I give up.  The only thing I can suggest is asking on the comp.lang.perl
newsgroup for someone else who has an OSF/2 machine and has successfully
installed perl.  There may be some magic handwaving/virgin sacrifices required
to get sockets to work.

If you can't find someone, then I think you should borrow someone else's
system (there's got to be at least one good machine at NCSU) and run the
programs remotely.

Good luck,

......Roy Fielding   ICS Grad Student, University of California, Irvine  USA
                                     <fielding@ics.uci.edu>
                     <URL:http://www.ics.uci.edu/dir/grad/Software/fielding>