From tri@pooh.tky.hut.fi  Thu Sep 25 07:07:53 1997
Received: from vipunen.hut.fi (root@vipunen.hut.fi [130.233.224.20])
          by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id HAA18095
          for <FreeBSD-gnats-submit@freebsd.org>; Thu, 25 Sep 1997 07:07:50 -0700 (PDT)
Received: from pooh.tky.hut.fi (pooh.tky.hut.fi [130.233.23.135])
	by vipunen.hut.fi (8.8.7/8.8.7) with ESMTP id RAA11334
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 25 Sep 1997 17:07:46 +0300
Received: by pooh.tky.hut.fi (RAA24112); Thu, 25 Sep 1997 17:07:46 +0300 (EEST)
Message-Id: <199709251407.RAA24112@pooh.tky.hut.fi>
Date: Thu, 25 Sep 1997 17:07:46 +0300 (EEST)
From: "Timo J. Rinne" <tri@pooh.tky.hut.fi>
Reply-To: tri@pooh.tky.hut.fi
To: FreeBSD-gnats-submit@freebsd.org
Subject: fetch(3) doesn't get asctime(3) format
X-Send-Pr-Version: 3.2

>Number:         4625
>Category:       bin
>Synopsis:       fetch(3) doesn't get asctime(3) format
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:
>Keywords:
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Sep 25 07:10:00 PDT 1997
>Closed-Date:    Sun Sep 28 04:28:12 PDT 1997
>Last-Modified:  Sun Sep 28 04:29:34 PDT 1997
>Originator:     Timo J. Rinne
>Release:        FreeBSD 3.0-CURRENT i386
>Organization:
PR
>Environment:

	FreeBSD-3.0-070897

>Description:

	Command fetch(3) gives a warning, if remote httpd gives
	date in headers in asctime(3) format.  This is due to
	simple bug.

>How-To-Repeat:
	Use httpd that uses asctime(3) format.

>Fix:
Simple.
*** http.c      Thu Sep 25 16:55:33 1997
--- http.c.orig Thu Sep 25 17:05:17 1997
***************
*** 1297,1303 ****
  
        } else if (string[3] == ' ') {
                /* Mon Jan 27 14:25:20 1997 */
!               if (strlen(string) < 24)
                        return -1;
                string += 4;
                for (i = 0; i < 12; i++) {
--- 1297,1303 ----
  
        } else if (string[3] == ' ') {
                /* Mon Jan 27 14:25:20 1997 */
!               if (strlen(string) < 25)
                        return -1;
                string += 4;
                for (i = 0; i < 12; i++) {

And here we go.

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: cracauer 
State-Changed-When: Sun Sep 28 04:28:12 PDT 1997 
State-Changed-Why:  
Provided patch reviewed and commited. 

Thanks! 

Martin 

>Unformatted:
