[461] in Pthreads mailing list archive

home help back first fref pref prev next nref lref last post

Re: Accept/Getpeername calls

daemon@ATHENA.MIT.EDU (Larry V. Streepy, Jr.)
Mon Oct 14 11:54:14 1996

Date: Mon, 14 Oct 1996 09:33:58 -0600
From: "Larry V. Streepy, Jr." <streepy@healthcare.com>
To: Ranil De Silva <ranil@ee.uts.edu.au>
Cc: pthreads@MIT.EDU

Ranil De Silva wrote:
> 
> I was wondering if anyone else has encountered problems with the
> accept/getpeername calls to do with setting of the peer address.
> If so are their any patches for this.

I think the fix you need is a single line change to res_internal.c, here
it is:

RCS file: /usr/cvssrc/pthreads-1_60_beta5/net/res_internal.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -c -r1.1 -r1.2
*** res_internal.c      1996/02/09 05:39:53     1.1
--- res_internal.c      1996/10/06 00:19:49     1.2
***************
*** 144,149 ****
--- 144,150 ----
                                break;
                        cp += n;
                        result->h_name = bp;
+                       bp += strlen(bp) + 1;
                        iquery_done = 1;
                        break;
                }

-- 
Larry V. Streepy, Jr.
Chief Technical Officer,  Healthcare Communications, Inc.
mailto:streepy@healthcare.com
(214) 851-7033 (Dallas Main #)
(970) 626-5028 (My office #)			(970) 626-4425  (Fax)

home help back first fref pref prev next nref lref last post