On Dec 3 04:29, Brian Dessent wrote:
> John Emmas wrote:
>
> > Forgive me - but as someone who's very new to socket programming, I'm
> > confused about why the program worked when I built it under Linux. Is it
> > because something would have converted "localhost" to an IP address (is this
> > t
John Emmas wrote:
> Forgive me - but as someone who's very new to socket programming, I'm
> confused about why the program worked when I built it under Linux. Is it
> because something would have converted "localhost" to an IP address (is this
> the lookup stuff that you referred to?) and where c
John Emmas wrote:
confused about why the program worked when I built it under Linux.
As Brian said, glibc's inet_pton() is apparently doing something beyond
what the standard requires. Cygwin doesn't use glibc, it uses a
different standard C library called newlib.
--
Unsubscribe info:
- Original Message -
From: "Brian Dessent"
Subject: Re: Socket programming with Cygwin
The call fails because addr is junk, because the demo passed "localhost"
to inet_pton. According to the docs, this function only takes IP
addresses. If you change simple_clien
John Emmas wrote:
> In every case, the programs fail when the client attempts to connect to the
> server. This would be a typical line:-
>
> status = ::connect ( m_sock, ( sockaddr * ) &addr, sizeof ( addr ) );
>
> 'status' receives -1 and if I check the error it's invariably something like
> "
5 matches
Mail list logo