From nobody@FreeBSD.ORG  Fri Jul 28 01:52:28 2000
Return-Path: <nobody@FreeBSD.ORG>
Received: by hub.freebsd.org (Postfix, from userid 32767)
	id 3769F37B50D; Fri, 28 Jul 2000 01:52:23 -0700 (PDT)
Message-Id: <20000728085223.3769F37B50D@hub.freebsd.org>
Date: Fri, 28 Jul 2000 01:52:23 -0700 (PDT)
From: taguchi@tohoku.iij.ad.jp
Sender: nobody@FreeBSD.ORG
To: freebsd-gnats-submit@FreeBSD.org
Subject: fetch(1) on 4.1 requires MDTM
X-Send-Pr-Version: www-1.0

>Number:         20236
>Category:       bin
>Synopsis:       fetch(1) on 4.1 requires MDTM
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    des
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jul 28 02:00:00 PDT 2000
>Closed-Date:    Fri Jul 28 03:36:19 PDT 2000
>Last-Modified:  Fri Jul 28 03:36:43 PDT 2000
>Originator:     Taguchi, Takeshi
>Release:        4.1-stable
>Organization:
IIJ
>Environment:
FreeBSD hoya 4.1-STABLE FreeBSD 4.1-STABLE #0: Fri Jul 28 14:21:41 JST 2000     root@hoya:/usr/obj/usr/src/sys/HOYA  i386

>Description:
Since 4.1R, fetch requires MTDM supports to ftpd.
Because in /usr/src/lib/libfetch/ftp.c:

static int
_ftp_stat(int cd, char *file, struct url_stat *us)
{
                ......
   if ((e = _ftp_cmd(cd, "MDTM %s", s)) != FTP_FILE_STATUS) {
	_ftp_seterr(e);
	return -1; /* HERE!! */
   }
                ......
}

So if ftpd does not support MTDM, then connection will be
closed.

MTDM is NOT RFC yet.
And some ftpds do NOT support MTDM.
Such as Solaris2.8's one, and MS ftpd version4.
This means fetch(1) on 4.1R can not talk them!


>How-To-Repeat:

>Fix:
Sorry, I can't make patch.

I think

   if ((e = _ftp_cmd(cd, "MDTM %s", s)) != FTP_FILE_STATUS) {
	/* _ftp_seterr(e);
	return -1;  */
             ln = "000000000000"; /* or more better value */
   }

may be work.... Is this correct?


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->des 
Responsible-Changed-By: sheldonh 
Responsible-Changed-When: Fri Jul 28 02:42:43 PDT 2000 
Responsible-Changed-Why:  
Over to the maintainer. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=20236 
State-Changed-From-To: open->closed 
State-Changed-By: des 
State-Changed-When: Fri Jul 28 03:36:19 PDT 2000 
State-Changed-Why:  
Already fixed. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=20236 
>Unformatted:
