From owner-freebsd-current Wed Aug 16 2:18:13 2000 Delivered-To: freebsd-current@freebsd.org Received: from whale.sunbay.crimea.ua (whale.sunbay.crimea.ua [212.110.138.65]) by hub.freebsd.org (Postfix) with ESMTP id 808B737C012 for ; Wed, 16 Aug 2000 02:18:06 -0700 (PDT) (envelope-from ru@whale.sunbay.crimea.ua) Received: (from ru@localhost) by whale.sunbay.crimea.ua (8.9.3/1.13) id MAA45640; Wed, 16 Aug 2000 12:17:51 +0300 (EEST) Date: Wed, 16 Aug 2000 12:17:51 +0300 From: Ruslan Ermilov To: Network Cc: freebsd-current@FreeBSD.org Subject: Re: ftpd not working with 4.1-stable Message-ID: <20000816121751.A44967@sunbay.com> Mail-Followup-To: Network , freebsd-current@FreeBSD.org References: <000801c0074f$2a243280$0300a8c0@nubian.net> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="sm4nu43k4a2Rpi4c" X-Mailer: Mutt 1.0i In-Reply-To: <000801c0074f$2a243280$0300a8c0@nubian.net>; from edukation@crosswinds.net on Wed, Aug 16, 2000 at 02:56:54AM -0400 Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG --sm4nu43k4a2Rpi4c Content-Type: text/plain; charset=us-ascii On Wed, Aug 16, 2000 at 02:56:54AM -0400, Network wrote: > > > Inetd is disabled with .. inetd_enable="NO" > > I cannot start ftpd from the cmd line using; /usr/libexec/ftpd -D -S -l -a > xxx.xxx.xx.xx -OR- /usr/libexec/ftpd -D -a xxx.xxx.xx.xx > > Error= Aug 16 01:19:52 The-Raven ftpd[988]: getpeername (/usr/libexec/ftpd): > Socket operation > Aug 16 01:23:28 The-Raven ftpd[1007]: control socket: Protocol not > supported > > The first error line has never showed itself again. The second error line > happens on both of my 4.1-stable machines. > > At the time of this writing I wasn't able to search the mail list for > possible fixes or answers. > I have just fixed that in CURRENT. Please try the following patch, it should apply cleanly to your 4.1-STABLE sources. Cheers, -- Ruslan Ermilov Oracle Developer/DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age --sm4nu43k4a2Rpi4c Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=p Index: ftpd.c =================================================================== RCS file: /home/ncvs/src/libexec/ftpd/ftpd.c,v retrieving revision 1.65 retrieving revision 1.66 diff -u -p -r1.65 -r1.66 --- ftpd.c 2000/08/01 13:58:55 1.65 +++ ftpd.c 2000/08/16 09:12:33 1.66 @@ -408,8 +408,6 @@ main(argc, argv, envp) error = getaddrinfo(bindname, "ftp", &hints, &res); } - if (error == 0 && res->ai_addr != NULL) - family = res->ai_addr->sa_family; } if (error) { syslog(LOG_ERR, gai_strerror(error)); @@ -420,7 +418,8 @@ main(argc, argv, envp) if (res->ai_addr == NULL) { syslog(LOG_ERR, "-a %s: getaddrinfo failed", hostname); exit(1); - } + } else + family = res->ai_addr->sa_family; /* * Open a socket, bind it to the FTP port, and start * listening. --sm4nu43k4a2Rpi4c-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message