Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 May 2000 05:16:55 +0900 (JST)
From:      Hajimu UMEMOTO (=?ISO-2022-JP?B?GyRCR19LXBsoQiA=?=  =?ISO-2022-JP?B?GyRCSCUbKEI=?=) <ume@mahoroba.org>
To:        des@flood.ping.uio.no
Cc:        arch@freebsd.org
Subject:   Re: fetch(1)
Message-ID:  <200005122016.e4CKGtF38185@peace.mahoroba.org>
In-Reply-To: <xzpbt2djcj4.fsf@flood.ping.uio.no>
References:  <xzpbt2djcj4.fsf@flood.ping.uio.no>

next in thread | previous in thread | raw e-mail | index | archive | help
>>>>> On 11 May 2000 18:07:43 +0200
>>>>> Dag-Erling Smorgrav <des@flood.ping.uio.no> said:

des> I'm still waiting for comments about my libfetch-based fetch(1). Get
des> the latest tarball from <URL:http://www.freebsd.org/~des/software/>.

des> (note that it needs -CURRENT's libfetch to work)

I wrote IPv6 support part of it and now testing.

	http://www.imasy.or.jp/~ume/ipv6/FreeBSD/libfetch-ipv6.diff.gz
	http://www.imasy.or.jp/~ume/ipv6/FreeBSD/fetch-20000508-ipv6.diff

Your fetch(1) doesn't handle content size correctly on some case.  If
HTTP server doesn't reply Content-Length:, fetchStat()
(fetchStatHTTP()) doesn't return -1 and doesn't touch us.size.  Then,
the value of us.size stays unknown.

--- fetch.c.orig	Mon May  8 16:28:00 2000
+++ fetch.c	Sat May 13 05:10:38 2000
@@ -129,7 +139,8 @@
      * alarm(timeout) further down.
      */
     fetchTimeout = timeout;
-    
+
+    us.size = -1;
     alarm(timeout);
     if (fetchStat(url, &us, flags) == -1) {
 	warnx("%s: size not known", path);

--
Hajimu UMEMOTO @ Internet Mutual Aid Society Yokohama, Japan
ume@mahoroba.org  ume@bisd.hitachi.co.jp  ume@FreeBSD.org
http://www.imasy.org/~ume/


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-arch" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200005122016.e4CKGtF38185>