Subject: ftp/telnet/whatever name resolution trouble
To: None <tech-net@netbvd.org, current-users@netbsd.org>
From: None <itojun@iijlab.net>
List: current-users
Date: 07/06/1999 11:05:09
	Hello, I got several reports for name resolution error after
	ftp/telnet/whatever update for dual stack support in NetBSD-current.
	The trouble arise when you have "hosts: files dns" line in
	/etc/nsswitch.conf.

	I believe the following fixes your problem.  If you still see
	the problem, please contact me.

	Sorry for make you waited and thanks very much for your reports!

	(Could anybody who is using NIS check the behavior or resolver?)

itojun


------- Forwarded Message

	by coconut.itojun.org (8.9.3+3.2W/3.7W) with SMTP id LAA00281
	for <itojun@itojun.org>; Tue, 6 Jul 1999 11:01:29 +0900 (JST)
  by redmail.netbsd.org with SMTP; 6 Jul 1999 02:00:42 -0000
	by nb00.nas.nasa.gov (8.8.8/8.8.8) id TAA22870;
	Mon, 5 Jul 1999 19:00:42 -0700 (PDT)
Date: Mon, 5 Jul 1999 19:00:42 -0700 (PDT)
From: Jun-ichiro itojun Hagino <itojun@netbsd.org>
Message-Id: <199907060200.TAA22870@nb00.nas.nasa.gov>
Subject: CVS commit: basesrc
To: source-changes@netbsd.org
Reply-To: itojun@netbsd.org
Sender: source-changes-owner@netbsd.org


Module Name:	basesrc
Committed By:	itojun
Date:		Tue Jul  6 02:00:42 UTC 1999

Modified Files:
	basesrc/lib/libc/net: getaddrinfo.c gethnamaddr.c

Log Message:
fix name resolution problem when you have "hosts: files dns" on
/etc/nsswitch.conf.

This was because of two reasons:
- - /etc/hosts lookup code damaged some of internal
  state used by gethostbyname2().
- - getaddrinfo() was not persistent enough against errors.

Sorry for the delay, and hope this fix all the following PRs
(I checked in my environment immitating those PRs and it worked for me)
PR: 7901, 7912, 7921


To generate a diff of this commit:
cvs rdiff -r1.7 -r1.8 basesrc/lib/libc/net/getaddrinfo.c
cvs rdiff -r1.20 -r1.21 basesrc/lib/libc/net/gethnamaddr.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.


------- End of Forwarded Message