GNU bug report logs - #15227
Possible bug in (web server)

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: guile; Reported by: Shane Celis <shane.celis@HIDDEN>; dated Sat, 31 Aug 2013 07:12:02 UTC; Maintainer for guile is bug-guile@HIDDEN.

Message received at 15227 <at> debbugs.gnu.org:


Received: (at 15227) by debbugs.gnu.org; 29 Apr 2017 20:38:41 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Apr 29 16:38:40 2017
Received: from localhost ([127.0.0.1]:46705 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1d4Z8a-0003uE-En
	for submit <at> debbugs.gnu.org; Sat, 29 Apr 2017 16:38:40 -0400
Received: from mail-pg0-f42.google.com ([74.125.83.42]:35655)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <matt.wette@HIDDEN>) id 1d4Z8Y-0003u1-3i
 for 15227 <at> debbugs.gnu.org; Sat, 29 Apr 2017 16:38:39 -0400
Received: by mail-pg0-f42.google.com with SMTP id o3so24535998pgn.2
 for <15227 <at> debbugs.gnu.org>; Sat, 29 Apr 2017 13:38:38 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=from:mime-version:subject:message-id:date:to;
 bh=V55ADPhBUj5z5EgotdNpUTbVNEb2Yr9gqWsJONjEHM0=;
 b=Lf/fdpI9y5EP5iT/aeIHM1TsASM9IscjoMbXYmkaPO0fcQvO7oIMNg0rJCJMbtYz/a
 upsHR4oQUl9ZmcUwiPInkd6lXOPOF32WgzEozuwz01QL3LUZcQgfhJG2yWI/Ch9ejILJ
 t8PSteJSHnK+huN4jaX9Y4EjkSFV170LNpQuU8WvwDoqJJt7j7D254kjFy4rZV/xVYH/
 vC1S6b0n0lR5qXtlnjlvVLiEz4qegawyOqh5GfeRQTEqp2wnflnsQl21RJ2+YvsxM9la
 xLwyOb3wnGpYRn9VJIUNWmRv7rpypTeuilT3sSTLeaCDJok8sbDbm3BK8jR+NAGIrK50
 KZxA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:from:mime-version:subject:message-id:date:to;
 bh=V55ADPhBUj5z5EgotdNpUTbVNEb2Yr9gqWsJONjEHM0=;
 b=dz4O79i1JTrywMt8TFi4X0By2xzUEnlaS0QZUF5+O8sDGPw2rASbALk4aHbJBToFrC
 iT3w93BtC9cepxNz2B1SsVysflNhjx9ZgrArkx1tU+hZlmF3oplhP9tjXnle4C3mJg89
 /Tf/xq8LgHcQp8EKxNze74lLATpAHhA3pT7ihLxhu6XauWsvTcvqVJB/VvPGD0sN4cwW
 pSx0/igGhyP2qMxZpS0N7XXpf9KA0XF5OYCKnUm+zDBVmSxXFN+9QDK5ivMIPpUFU/hZ
 HHveHou2Rww01ZQKmCoZpCxTaPaV31s2Ig48YXJqlzOfoGkX0dlD8WV5VDiC4kZ+sIc4
 EBOw==
X-Gm-Message-State: AN3rC/6dOQGHXVqX5WBRr2U5XkhPbGB/4bA7mqzGREdNYTPSPM7KR+7B
 sQ4k0HLyyII0UNargks=
X-Received: by 10.99.111.1 with SMTP id k1mr18969144pgc.194.1493498311687;
 Sat, 29 Apr 2017 13:38:31 -0700 (PDT)
Received: from [192.168.2.114] (216-165-236-44.championbroadband.com.
 [216.165.236.44])
 by smtp.gmail.com with ESMTPSA id m4sm20818707pgm.25.2017.04.29.13.38.29
 for <15227 <at> debbugs.gnu.org>
 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Sat, 29 Apr 2017 13:38:30 -0700 (PDT)
From: Matt Wette <matt.wette@HIDDEN>
Content-Type: multipart/alternative;
 boundary="Apple-Mail=_5ABC9768-8E04-4C8A-9B8D-D0DD930B6570"
Mime-Version: 1.0 (Mac OS X Mail 10.3 \(3273\))
Subject: Possible bug in (web server)
Message-Id: <6C41D7C3-BE4C-4839-A47A-30B08B4E195B@HIDDEN>
Date: Sat, 29 Apr 2017 13:38:28 -0700
To: 15227 <at> debbugs.gnu.org
X-Mailer: Apple Mail (2.3273)
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 15227
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.0 (/)


--Apple-Mail=_5ABC9768-8E04-4C8A-9B8D-D0DD930B6570
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain;
	charset=utf-8


I tried this on guile 2.2.0 and the localhost queries seem to work OK. =
=E2=80=94 Matt



mwette$ ./15227 server
;;; note: auto-compilation is enabled, set GUILE_AUTO_COMPILE=3D0
;;;       or pass the --no-auto-compile argument to disable.
;;; compiling /Users/mwette/proj/scheme/guile/bugs-guile/./15227
;;; compiled =
/Users/mwette/.cache/guile/ccache/2.2-LE-8-3.9/Users/mwette/proj/scheme/gu=
ile/bugs-guile/15227.go
Web server replied 'Hello World! 0'.
Web server replied 'Hello World! 1'.
Web server replied 'Hello World! 2'.
Web server replied 'Hello World! 3'.



mwette$ ./15227 client
Getting http://gnu.org... response #<<response> version: (1 . 1) code: =
301 reason-phrase: "Moved Permanently" headers: ((date . #<date =
nanosecond: 0 second: 12 minute: 33 hour: 20 day: 29 month: 4 year: 2017 =
zone-offset: 0>) (server . "Apache/2.4.7") (location . #<<uri> scheme: =
http userinfo: #f host: "www.gnu.org" port: #f path: "/" query: #f =
fragment: #f>) (content-length . 290) (connection close) (content-type =
text/html (charset . "iso-8859-1"))) port: #<closed: file 1021b0690>>

Getting http://fsf.org... response #<<response> version: (1 . 0) code: =
301 reason-phrase: "Moved Permanently" headers: ((server . =
"nginx/1.1.19") (date . #<date nanosecond: 0 second: 42 minute: 36 hour: =
20 day: 29 month: 4 year: 2017 zone-offset: 0>) (content-type text/html) =
(content-length . 185) (location . #<<uri> scheme: http userinfo: #f =
host: "www.fsf.org" port: #f path: "/" query: #f fragment: #f>) (x-cache =
. "MISS from www.fsforg") (x-cache-lookup . "MISS from www.fsforg:80") =
(via "1.0 www.fsforg (squid/3.1.19)") (connection close)) port: =
#<closed: file 1021b03f0>>

Getting http://localhost:8080... response #<<response> version: (1 . 1) =
code: 200 reason-phrase: "OK" headers: ((content-length . 14) =
(content-type text/plain (charset . "utf-8"))) port: #<closed: file =
1021b0000>>

Getting http://localhost:8080... response #<<response> version: (1 . 1) =
code: 200 reason-phrase: "OK" headers: ((content-length . 14) =
(content-type text/plain (charset . "utf-8"))) port: #<closed: file =
1022d1c40>>

mwette$ ./15227 client
Getting http://gnu.org... response #<<response> version: (1 . 1) code: =
301 reason-phrase: "Moved Permanently" headers: ((date . #<date =
nanosecond: 0 second: 28 minute: 33 hour: 20 day: 29 month: 4 year: 2017 =
zone-offset: 0>) (server . "Apache/2.4.7") (location . #<<uri> scheme: =
http userinfo: #f host: "www.gnu.org" port: #f path: "/" query: #f =
fragment: #f>) (content-length . 290) (connection close) (content-type =
text/html (charset . "iso-8859-1"))) port: #<closed: file 107eb9690>>

Getting http://fsf.org... response #<<response> version: (1 . 0) code: =
301 reason-phrase: "Moved Permanently" headers: ((server . =
"nginx/1.1.19") (date . #<date nanosecond: 0 second: 58 minute: 36 hour: =
20 day: 29 month: 4 year: 2017 zone-offset: 0>) (content-type text/html) =
(content-length . 185) (location . #<<uri> scheme: http userinfo: #f =
host: "www.fsf.org" port: #f path: "/" query: #f fragment: #f>) (x-cache =
. "MISS from www.fsforg") (x-cache-lookup . "MISS from www.fsforg:80") =
(via "1.0 www.fsforg (squid/3.1.19)") (connection close)) port: =
#<closed: file 107eb93f0>>

Getting http://localhost:8080... response #<<response> version: (1 . 1) =
code: 200 reason-phrase: "OK" headers: ((content-length . 14) =
(content-type text/plain (charset . "utf-8"))) port: #<closed: file =
107eb9000>>

Getting http://localhost:8080... response #<<response> version: (1 . 1) =
code: 200 reason-phrase: "OK" headers: ((content-length . 14) =
(content-type text/plain (charset . "utf-8"))) port: #<closed: file =
107fd9c40>>

mwette$ uname -a
Darwin nautilus 16.5.0 Darwin Kernel Version 16.5.0: Fri Mar  3 16:52:33 =
PST 2017; root:xnu-3789.51.2~3/RELEASE_X86_64 x86_64

mwette$ guile22 --version
guile (GNU Guile) 2.2.0
Copyright (C) 2017 Free Software Foundation, Inc.

License LGPLv3+: GNU LGPL 3 or later =
<http://gnu.org/licenses/lgpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.


--Apple-Mail=_5ABC9768-8E04-4C8A-9B8D-D0DD930B6570
Content-Transfer-Encoding: quoted-printable
Content-Type: text/html;
	charset=utf-8

<html><head><meta http-equiv=3D"Content-Type" content=3D"text/html =
charset=3Dutf-8"></head><body style=3D"word-wrap: break-word; =
-webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" =
class=3D""><div class=3D""><br class=3D""></div><div class=3D"">I tried =
this on guile 2.2.0 and the localhost queries seem to work OK. =E2=80=94 =
Matt</div><div class=3D""><br class=3D""></div><div class=3D""><br =
class=3D""></div><div class=3D""><br class=3D""></div><div class=3D""><div=
 style=3D"margin: 0px; font-size: 13px; line-height: normal; =
font-family: Menlo; background-color: rgb(255, 255, 255);" =
class=3D""><span style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D"">mwette$ ./15227 server</span></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">;;; =
note: auto-compilation is enabled, set =
GUILE_AUTO_COMPILE=3D0</span></div><div style=3D"margin: 0px; font-size: =
13px; line-height: normal; font-family: Menlo; background-color: =
rgb(255, 255, 255);" class=3D""><span style=3D"font-variant-ligatures: =
no-common-ligatures" class=3D"">;;; &nbsp; &nbsp; &nbsp; or pass the =
--no-auto-compile argument to disable.</span></div><div style=3D"margin: =
0px; font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">;;; =
compiling =
/Users/mwette/proj/scheme/guile/bugs-guile/./15227</span></div><div =
style=3D"margin: 0px; font-size: 13px; line-height: normal; font-family: =
Menlo; background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">;;; =
compiled =
/Users/mwette/.cache/guile/ccache/2.2-LE-8-3.9/Users/mwette/proj/scheme/gu=
ile/bugs-guile/15227.go</span></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Web =
server replied 'Hello World! 0'.</span></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Web =
server replied 'Hello World! 1'.</span></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Web =
server replied 'Hello World! 2'.</span></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Web =
server replied 'Hello World! 3'.</span></div></div><div class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D""><br =
class=3D""></span></div><div class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D""><br =
class=3D""></span></div><div class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D""><br =
class=3D""></span></div><div class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D""><div =
style=3D"margin: 0px; font-size: 13px; line-height: normal; font-family: =
Menlo; background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">mwette$ =
./15227 client</span></div><div style=3D"margin: 0px; font-size: 13px; =
line-height: normal; font-family: Menlo; background-color: rgb(255, 255, =
255);" class=3D""><span style=3D"font-variant-ligatures: =
no-common-ligatures" class=3D"">Getting <a href=3D"http://gnu.org" =
class=3D"">http://gnu.org</a>... response #&lt;&lt;response&gt; version: =
(1 . 1) code: 301 reason-phrase: "Moved Permanently" headers: ((date . =
#&lt;date nanosecond: 0 second: 12 minute: 33 hour: 20 day: 29 month: 4 =
year: 2017 zone-offset: 0&gt;) (server . "Apache/2.4.7") (location . =
#&lt;&lt;uri&gt; scheme: http userinfo: #f host: "<a =
href=3D"http://www.gnu.org" class=3D"">www.gnu.org</a>" port: #f path: =
"/" query: #f fragment: #f&gt;) (content-length . 290) (connection =
close) (content-type text/html (charset . "iso-8859-1"))) port: =
#&lt;closed: file 1021b0690&gt;&gt;</span></div><div style=3D"margin: =
0px; font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255); min-height: 15px;" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D""></span><br class=3D""></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Getting =
<a href=3D"http://fsf.org" class=3D"">http://fsf.org</a>... response =
#&lt;&lt;response&gt; version: (1 . 0) code: 301 reason-phrase: "Moved =
Permanently" headers: ((server . "nginx/1.1.19") (date . #&lt;date =
nanosecond: 0 second: 42 minute: 36 hour: 20 day: 29 month: 4 year: 2017 =
zone-offset: 0&gt;) (content-type text/html) (content-length . 185) =
(location . #&lt;&lt;uri&gt; scheme: http userinfo: #f host: "<a =
href=3D"http://www.fsf.org" class=3D"">www.fsf.org</a>" port: #f path: =
"/" query: #f fragment: #f&gt;) (x-cache . "MISS from www.fsforg") =
(x-cache-lookup . "MISS from www.fsforg:80") (via "1.0 www.fsforg =
(squid/3.1.19)") (connection close)) port: #&lt;closed: file =
1021b03f0&gt;&gt;</span></div><div style=3D"margin: 0px; font-size: =
13px; line-height: normal; font-family: Menlo; background-color: =
rgb(255, 255, 255); min-height: 15px;" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D""></span><br class=3D""></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Getting =
<a href=3D"http://localhost:8080" class=3D"">http://localhost:8080</a>... =
response #&lt;&lt;response&gt; version: (1 . 1) code: 200 reason-phrase: =
"OK" headers: ((content-length . 14) (content-type text/plain (charset . =
"utf-8"))) port: #&lt;closed: file 1021b0000&gt;&gt;</span></div><div =
style=3D"margin: 0px; font-size: 13px; line-height: normal; font-family: =
Menlo; background-color: rgb(255, 255, 255); min-height: 15px;" =
class=3D""><span style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D""></span><br class=3D""></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Getting =
<a href=3D"http://localhost:8080" class=3D"">http://localhost:8080</a>... =
response #&lt;&lt;response&gt; version: (1 . 1) code: 200 reason-phrase: =
"OK" headers: ((content-length . 14) (content-type text/plain (charset . =
"utf-8"))) port: #&lt;closed: file 1022d1c40&gt;&gt;</span></div><div =
style=3D"margin: 0px; font-size: 13px; line-height: normal; font-family: =
Menlo; background-color: rgb(255, 255, 255); min-height: 15px;" =
class=3D""><span style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D""></span><br class=3D""></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">mwette$ =
./15227 client</span></div><div style=3D"margin: 0px; font-size: 13px; =
line-height: normal; font-family: Menlo; background-color: rgb(255, 255, =
255);" class=3D""><span style=3D"font-variant-ligatures: =
no-common-ligatures" class=3D"">Getting <a href=3D"http://gnu.org" =
class=3D"">http://gnu.org</a>... response #&lt;&lt;response&gt; version: =
(1 . 1) code: 301 reason-phrase: "Moved Permanently" headers: ((date . =
#&lt;date nanosecond: 0 second: 28 minute: 33 hour: 20 day: 29 month: 4 =
year: 2017 zone-offset: 0&gt;) (server . "Apache/2.4.7") (location . =
#&lt;&lt;uri&gt; scheme: http userinfo: #f host: "<a =
href=3D"http://www.gnu.org" class=3D"">www.gnu.org</a>" port: #f path: =
"/" query: #f fragment: #f&gt;) (content-length . 290) (connection =
close) (content-type text/html (charset . "iso-8859-1"))) port: =
#&lt;closed: file 107eb9690&gt;&gt;</span></div><div style=3D"margin: =
0px; font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255); min-height: 15px;" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D""></span><br class=3D""></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Getting =
<a href=3D"http://fsf.org" class=3D"">http://fsf.org</a>... response =
#&lt;&lt;response&gt; version: (1 . 0) code: 301 reason-phrase: "Moved =
Permanently" headers: ((server . "nginx/1.1.19") (date . #&lt;date =
nanosecond: 0 second: 58 minute: 36 hour: 20 day: 29 month: 4 year: 2017 =
zone-offset: 0&gt;) (content-type text/html) (content-length . 185) =
(location . #&lt;&lt;uri&gt; scheme: http userinfo: #f host: "<a =
href=3D"http://www.fsf.org" class=3D"">www.fsf.org</a>" port: #f path: =
"/" query: #f fragment: #f&gt;) (x-cache . "MISS from www.fsforg") =
(x-cache-lookup . "MISS from www.fsforg:80") (via "1.0 www.fsforg =
(squid/3.1.19)") (connection close)) port: #&lt;closed: file =
107eb93f0&gt;&gt;</span></div><div style=3D"margin: 0px; font-size: =
13px; line-height: normal; font-family: Menlo; background-color: =
rgb(255, 255, 255); min-height: 15px;" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D""></span><br class=3D""></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Getting =
<a href=3D"http://localhost:8080" class=3D"">http://localhost:8080</a>... =
response #&lt;&lt;response&gt; version: (1 . 1) code: 200 reason-phrase: =
"OK" headers: ((content-length . 14) (content-type text/plain (charset . =
"utf-8"))) port: #&lt;closed: file 107eb9000&gt;&gt;</span></div><div =
style=3D"margin: 0px; font-size: 13px; line-height: normal; font-family: =
Menlo; background-color: rgb(255, 255, 255); min-height: 15px;" =
class=3D""><span style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D""></span><br class=3D""></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Getting =
<a href=3D"http://localhost:8080" class=3D"">http://localhost:8080</a>... =
response #&lt;&lt;response&gt; version: (1 . 1) code: 200 reason-phrase: =
"OK" headers: ((content-length . 14) (content-type text/plain (charset . =
"utf-8"))) port: #&lt;closed: file 107fd9c40&gt;&gt;</span></div><div =
class=3D""><span style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D""><br class=3D""></span></div><div class=3D""><div =
style=3D"margin: 0px; font-size: 13px; line-height: normal; font-family: =
Menlo; background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">mwette$ =
uname -a</span></div><div style=3D"margin: 0px; font-size: 13px; =
line-height: normal; font-family: Menlo; background-color: rgb(255, 255, =
255);" class=3D""><span style=3D"font-variant-ligatures: =
no-common-ligatures" class=3D"">Darwin nautilus 16.5.0 Darwin Kernel =
Version 16.5.0: Fri Mar&nbsp; 3 16:52:33 PST 2017; =
root:xnu-3789.51.2~3/RELEASE_X86_64 x86_64</span></div><div =
style=3D"margin: 0px; font-size: 13px; line-height: normal; font-family: =
Menlo; background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D""><br =
class=3D""></span></div><div style=3D"margin: 0px; font-size: 13px; =
line-height: normal; font-family: Menlo; background-color: rgb(255, 255, =
255);" class=3D""><span style=3D"font-variant-ligatures: =
no-common-ligatures" class=3D"">mwette$ guile22 =
--version</span></div><div style=3D"margin: 0px; font-size: 13px; =
line-height: normal; font-family: Menlo; background-color: rgb(255, 255, =
255);" class=3D""><span style=3D"font-variant-ligatures: =
no-common-ligatures" class=3D"">guile (GNU Guile) 2.2.0</span></div><div =
style=3D"margin: 0px; font-size: 13px; line-height: normal; font-family: =
Menlo; background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">Copyright=
 (C) 2017 Free Software Foundation, Inc.</span></div><div style=3D"margin:=
 0px; font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255); min-height: 15px;" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D""></span><br class=3D""></div><div style=3D"margin: 0px; =
font-size: 13px; line-height: normal; font-family: Menlo; =
background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">License =
LGPLv3+: GNU LGPL 3 or later &lt;<a =
href=3D"http://gnu.org/licenses/lgpl.html" =
class=3D"">http://gnu.org/licenses/lgpl.html</a>&gt;.</span></div><div =
style=3D"margin: 0px; font-size: 13px; line-height: normal; font-family: =
Menlo; background-color: rgb(255, 255, 255);" class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D"">This is =
free software: you are free to change and redistribute =
it.</span></div><div style=3D"margin: 0px; font-size: 13px; line-height: =
normal; font-family: Menlo; background-color: rgb(255, 255, 255);" =
class=3D""><span style=3D"font-variant-ligatures: no-common-ligatures" =
class=3D"">There is NO WARRANTY, to the extent permitted by =
law.</span></div></div><div class=3D""><span =
style=3D"font-variant-ligatures: no-common-ligatures" class=3D""><br =
class=3D""></span></div></span></div></body></html>=

--Apple-Mail=_5ABC9768-8E04-4C8A-9B8D-D0DD930B6570--




Information forwarded to bug-guile@HIDDEN:
bug#15227; Package guile. Full text available.

Message received at 15227 <at> debbugs.gnu.org:


Received: (at 15227) by debbugs.gnu.org; 21 Jun 2016 09:49:15 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jun 21 05:49:15 2016
Received: from localhost ([127.0.0.1]:48575 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1bFIJ0-0004iq-Ng
	for submit <at> debbugs.gnu.org; Tue, 21 Jun 2016 05:49:15 -0400
Received: from pb-sasl2.pobox.com ([64.147.108.67]:54310
 helo=sasl.smtp.pobox.com) by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <wingo@HIDDEN>) id 1bFIIz-0004ij-2O
 for 15227 <at> debbugs.gnu.org; Tue, 21 Jun 2016 05:49:13 -0400
Received: from sasl.smtp.pobox.com (unknown [127.0.0.1])
 by pb-sasl2.pobox.com (Postfix) with ESMTP id B4DDC21D41;
 Tue, 21 Jun 2016 05:49:12 -0400 (EDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc
 :subject:references:date:in-reply-to:message-id:mime-version
 :content-type; s=sasl; bh=M+i3NYXVDYe5g5v7UFintv0fw2E=; b=q8gIbi
 Y4JisHRzr7veeUHhHLBwRtPFdvWFUMnN+VfgIV/yJnR6f7FXUgR2Lhk42Ugk0vmP
 1U2qjplQt6bxZYAAqstcqUy7ggtQGbaWv9cNjkweaiP808hGLwgCKgFFB2jjczPy
 3rmx62Q/qxOhO5EWMiOiCGFwipCQ+x+QyXWHQ=
DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc
 :subject:references:date:in-reply-to:message-id:mime-version
 :content-type; q=dns; s=sasl; b=jIyzu3kbeFfuLB9ZffVnjqakmlryleWm
 mmiOCR4N8erqJSHbEauGX8HZ1E8YP6XFU/uiWocLSF8XTJizCyTDGCQxCOj/6L7l
 6pNISqJlUi9v9sOs9SEdUcAK9fiD7PhLfRHF5fKNxda0DlhfM2entM23vhRbJiHi
 8ctu/hv8Uc4=
Received: from pb-sasl2.nyi.icgroup.com (unknown [127.0.0.1])
 by pb-sasl2.pobox.com (Postfix) with ESMTP id AD6CE21D40;
 Tue, 21 Jun 2016 05:49:12 -0400 (EDT)
Received: from clucks (unknown [88.160.190.192])
 (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
 (No client certificate requested)
 by pb-sasl2.pobox.com (Postfix) with ESMTPSA id B313021D3E;
 Tue, 21 Jun 2016 05:49:11 -0400 (EDT)
From: Andy Wingo <wingo@HIDDEN>
To: Shane Celis <shane.celis@HIDDEN>
Subject: Re: bug#15227: Possible bug in (web server)
References: <CB238240-1C7E-4703-B8DB-733764230E5F@HIDDEN>
Date: Tue, 21 Jun 2016 11:49:04 +0200
In-Reply-To: <CB238240-1C7E-4703-B8DB-733764230E5F@HIDDEN> (Shane Celis's
 message of "Sat, 31 Aug 2013 03:11:10 -0400")
Message-ID: <87inx23m9b.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Pobox-Relay-ID: 68423EF8-3795-11E6-AD09-28A6F1301B6D-02397024!pb-sasl2.pobox.com
X-Spam-Score: -1.4 (-)
X-Debbugs-Envelope-To: 15227
Cc: 15227 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.4 (-)

I don't really understand this bug.  Ian's investigation isn't right, I
don't think; the "delimited" port stuff from (web response) should make
it correct to call get-bytevector-all on the response port.  So I think
there is not a client bug, but there may be a server bug on macOS.  Can
you retry on macOS with 2.0.11 and with 2.1.3 and see if the problem
still exists?

Thanks,

Andy

On Sat 31 Aug 2013 09:11, Shane Celis <shane.celis@HIDDEN> writes:

> Hi all,
>
> I found a bug in (web server) on Mac OS X, and when I compared against GNU/Linux I seem to have found a bug in (web client) there.  I've included a script and further details below.
>
> #!/usr/local/bin/guile \
> -e main -s
> !#
> ;; guile-web-server-osx-bug.scm
> ;;
> ;; This script demonstrates a possible bug in Guile's web server on
> ;; Mac OS X.  And it demonstrates a possible bug in Guile's web client
> ;; on GNU/Linux.
> ;;
> ;; Problem
> ;; =======
> ;;
> ;; Using Guile's (web server) with an example program, I ran into the
> ;; following issue on Mac OS X: If I ran
> ;; "./guile-web-server-osx-bug.scm server" and pointed my browser at
> ;; http://localhost:8080, the first request would work and be
> ;; displayed in my browser.  The second request would timeout.  I
> ;; compared this with Guile on GNU/Linux and found that the (web
> ;; server) worked fine, but the (web client) did not seem to work.
> ;;
> ;;
> ;; Reproduction
> ;; ============
> ;;
> ;; The script takes an argument "server" or "client [hostname/ip]".
> ;; When run as a server, it will say hello with an incremented
> ;; counter.  When run as a client, it will grab a couple of known
> ;; sites gnu.org, fsf.org, and then try localhost or the given
> ;; hostname on port 8080 twice, because on Mac OS X I saw the web
> ;; server work on the first request but not the second. The
> ;; hostname/ip the client is contacting is presumed to be a Guile web
> ;; server on the other end but doesn't have to be.
> ;;
> ;; If there were no bugs, this script should work like this:
> ;; $ ./guile-web-server-osx-bug.scm server &
> ;; Web server replied 'Hello World! 0'.
> ;; Web server replied 'Hello World! 1'.
> ;;
> ;; $ ./guile-web-server-osx-bug.scm client
> ;; Getting http://gnu.org... response #<<response> [...]
> ;;
> ;; Getting http://fsf.org... response #<<response> [...]
> ;;
> ;; Getting http://localhost:8080... response #<<response> [...]
> ;;
> ;; Getting http://localhost:8080... response #<<response> [...]
> ;;
> ;; Mac OS X bug
> ;; ------------
> ;;
> ;; Info
> ;; ----
> ;; 
> ;; $ uname -a
> ;; Darwin mbp13.local 12.4.0 Darwin Kernel Version 12.4.0: Wed May  1 17:57:12 PDT 2013; root:xnu-2050.24.15~1/RELEASE_X86_64 x86_64
> ;;
> ;; $ bash ./build-aux/config.guess
> ;; x86_64-apple-darwin12.4.0
> ;;
> ;; $ guile --version
> ;; guile (GNU Guile) 2.0.9 [...]
> ;;
> ;; $ ./config.status --config
> ;; 'LDFLAGS=-L/opt/local/lib' 'CPPFLAGS=-I/opt/local/include'
> ;;
> ;; Running
> ;; -------
> ;; 
> ;; $ ./guile-web-server-osx-bug.scm server 
> ;; Web server replied 'Hello World! 0'.
> ;;
> ;; --
> ;;
> ;; $ ./guile-web-server-osx-bug.scm client
> ;; Getting http://gnu.org... response #<<response> [...]
> ;;
> ;; Getting http://fsf.org... response #<<response> [...]
> ;;
> ;; Getting http://localhost:8080...SIGALRM called; timedout.
> ;; 
> ;; If I try to connect to http://localhost:8080 through a web browser,
> ;; it does not connect; however, the web server does report that it
> ;; has replied.
> ;;
> ;; GNU/Linux bug
> ;; ------------
> ;; 
> ;; Info
> ;; ----
> ;;
> ;; $ uname -a
> ;; Linux debian 3.2.0-4-686-pae #1 SMP Debian 3.2.46-1 i686 GNU/Linux
> ;;
> ;; $ guile --version
> ;; guile (GNU Guile) 2.0.9 [...]
> ;;
> ;; $ bash ./build-aux/config.guess
> ;; i686-pc-linux-gnu
> ;;
> ;; $ ./config.status --config
> ;;
> ;; Running
> ;; -------
> ;;
> ;; $ ./guile-web-server-osx-bug.scm server 
> ;; Web server replied 'Hello World! 0'.
> ;;
> ;; ---
> ;;
> ;; $ ./guile-web-server-osx-bug.scm client
> ;; Getting http://gnu.org... response #<<response> [...]
> ;;
> ;; Getting http://fsf.org... response #<<response> [...]
> ;;
> ;; Getting http://localhost:8080...SIGALRM called; timedout.
> ;;
> ;; If I try to connect to http://localhost:8080 through a web browser,
> ;; it works fine; so it seems like the (web client) is not working on
> ;; GNU/Linux and the (web server) is not working on Mac OS X.
> ;; 
>
> (use-modules (web server)
>              (web client)
>              (ice-9 optargs))
>
> (define count 0)
>
> (define (hello-world-handler request request-body)
>   (let ((reply (format #f "Hello World! ~a" count)))
>     (set! count (1+ count))
>     (format #t "Web server replied '~a'.~%" reply)
>     (values '((content-type . (text/plain)))
>             reply)))
>
> (define (start-server)
>    (run-server hello-world-handler 'http '(#:port 8080)))
>
> (define (check-url url)
>   (format #t "Getting ~a..." url)
>   (format #t " response ~a~%~%" (http-get url)))
>
> (define* (run-client #:optional (ip "localhost"))
>   (alarm 10)
>   ;; Test some URLs that should work.
>   (check-url "http://gnu.org")
>   (check-url "http://fsf.org")
>   ;; Try the web server's URL now twice.
>   (check-url (format #f "http://~a:8080" ip))
>   (check-url (format #f "http://~a:8080" ip)))
>
> (sigaction SIGALRM (lambda (sig)
>                      (format #t "SIGALRM called; timedout.~%")
>                      (exit 1)))
>
>
> (define (main args)
>   (unless (or (= 2 (length args))
>               (= 3 (length args)))
>     (format (current-error-port) "Usage: ~a <server|client [ip]>~%" (car args))
>     (exit 2))
>   (cond
>    ((string= "server" (cadr args))
>     (start-server))
>    ((string= "client" (cadr args))
>     (apply run-client (cddr args)))))




Information forwarded to bug-guile@HIDDEN:
bug#15227; Package guile. Full text available.

Message received at 15227 <at> debbugs.gnu.org:


Received: (at 15227) by debbugs.gnu.org; 13 Sep 2013 13:36:19 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Sep 13 09:36:19 2013
Received: from localhost ([127.0.0.1]:33069 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1VKTXm-0007pl-R9
	for submit <at> debbugs.gnu.org; Fri, 13 Sep 2013 09:36:19 -0400
Received: from mail-wg0-f41.google.com ([74.125.82.41]:40356)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <ianprice90@HIDDEN>) id 1VKTXj-0007pX-Uk
 for 15227 <at> debbugs.gnu.org; Fri, 13 Sep 2013 09:36:16 -0400
Received: by mail-wg0-f41.google.com with SMTP id l18so776492wgh.4
 for <15227 <at> debbugs.gnu.org>; Fri, 13 Sep 2013 06:36:10 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=googlemail.com; s=20120113;
 h=from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version:content-type;
 bh=pPPY+NANo4XlMuMigUwzCOAuVqrx9YKLNIuM97M7wKw=;
 b=Qk6nwFiG4tRFXEMLuTVAqnz+T0ib9yWIhQsslVAcZ/qGGlWMFYCUdoVmyc7nUUYl5t
 PbO38fPPYtUhomwgmOgnUkWfO8x30gFpkRZhh2elGr5Ut0bfaw8fV+s+svfGh8YkGzSM
 0C+OlcZYWB3b7MqG/vpgG1PmxSFT8gc0OAaBwfaxfWDYT/MZ9Q/RKNZuWY+LvaBlsymk
 DqIwuiW2a5VQoZofNIGPfOf30zEak4godTZFMI0w8vVIEIwOirO7rGlPePz/+ZytwO2D
 XQuK2lKYbWDoRja6ESFBTg261usv5rQNBy3F9rJfv/NH+FqGyLW8PlZaJwiccB0mYeD7
 zNpA==
X-Received: by 10.180.76.171 with SMTP id l11mr2586977wiw.39.1379079370068;
 Fri, 13 Sep 2013 06:36:10 -0700 (PDT)
Received: from Kagami.home (host109-150-135-12.range109-150.btcentralplus.com.
 [109.150.135.12])
 by mx.google.com with ESMTPSA id d11sm3627882wic.4.1969.12.31.16.00.00
 (version=TLSv1.2 cipher=RC4-SHA bits=128/128);
 Fri, 13 Sep 2013 06:36:09 -0700 (PDT)
From: Ian Price <ianprice90@HIDDEN>
To: Shane Celis <shane.celis@HIDDEN>
Subject: Re: bug#15227: Possible bug in (web server)
References: <CB238240-1C7E-4703-B8DB-733764230E5F@HIDDEN>
Date: Fri, 13 Sep 2013 14:36:04 +0100
In-Reply-To: <CB238240-1C7E-4703-B8DB-733764230E5F@HIDDEN> (Shane Celis's
 message of "Sat, 31 Aug 2013 03:11:10 -0400")
Message-ID: <87vc24zvwb.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-2022-jp
X-Spam-Score: -0.4 (/)
X-Debbugs-Envelope-To: 15227
Cc: 15227 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.4 (/)

Shane Celis <shane.celis@HIDDEN> writes:

> ;; GNU/Linux bug
> ;; ------------
> ;; 
> ;; Info
> ;; ----
> ;;
> ;; $ uname -a
> ;; Linux debian 3.2.0-4-686-pae #1 SMP Debian 3.2.46-1 i686 GNU/Linux
> ;;
> ;; $ guile --version
> ;; guile (GNU Guile) 2.0.9 [...]
> ;;
> ;; $ bash ./build-aux/config.guess
> ;; i686-pc-linux-gnu
> ;;
> ;; $ ./config.status --config
> ;;
> ;; Running
> ;; -------
> ;;
> ;; $ ./guile-web-server-osx-bug.scm server 
> ;; Web server replied 'Hello World! 0'.
> ;;
> ;; ---
> ;;
> ;; $ ./guile-web-server-osx-bug.scm client
> ;; Getting http://gnu.org... response #<<response> [...]
> ;;
> ;; Getting http://fsf.org... response #<<response> [...]
> ;;
> ;; Getting http://localhost:8080...SIGALRM called; timedout.
> ;;
> ;; If I try to connect to http://localhost:8080 through a web browser,
> ;; it works fine; so it seems like the (web client) is not working on
> ;; GNU/Linux and the (web server) is not working on Mac OS X.
> ;; 
If I run the client under strace I get

read(13, "HTTP/1.1 200 OK\r\nContent-Length: 15\r\nContent-Type: text/plain;charset=utf-8\r\n\r\nHello World! 22", 4096) = 94
read(13, 0xa1ec000, 4096)               = ? ERESTARTSYS (To be restarted if SA_RESTART is set)

so even though we've read all the data that's needed, we're still making
another call to read and blocking.

One problem was that read-response-body was making a call to
get-bytevector-all, but even after changing it to

(define (read-response-body r)
  "Reads the response body from R, as a bytevector.  Returns
‘#f’ if there was no response body."
  (let ((body (and=> (response-body-port r #:decode? #f)
                     (lambda (p)
                       (cond ((response-content-length r) =>
                              (lambda (n)
                                (get-bytevector-n p n)))
                             (else (get-bytevector-all p)))))))
    ;; Reading a body of length 0 will result in get-bytevector-all
    ;; returning the EOF object.
    (if (eof-object? body)
        #vu8()
        body)))

I'm still seeing the same behaviour. (I did check and the
get-bytevector-n case is definitely being ran)

So, I'm guessing the problem lies in the C code for handling ports,
and/or for handling sockets.

No idea why it doesn't happen on web calls but only localhost.

Aside:
The above change to read-response-body has not been committed. I'm
undecided as to whether or not read-response-body should handle checking
the size of the content body. Currently it doesn't, but we have separate
code for doing that in (web client), so maybe not. But it might be an
idea to document that read-response-body may return less bytes than the
content length.

-- 
Ian Price -- shift-reset.com

"Programming is like pinball. The reward for doing it well is
the opportunity to do it again" - from "The Wizardy Compiled"




Information forwarded to bug-guile@HIDDEN:
bug#15227; Package guile. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 31 Aug 2013 07:11:37 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Aug 31 03:11:37 2013
Received: from localhost ([127.0.0.1]:60748 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1VFfLM-0004pf-1s
	for submit <at> debbugs.gnu.org; Sat, 31 Aug 2013 03:11:36 -0400
Received: from eggs.gnu.org ([208.118.235.92]:37844)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <shane.celis@HIDDEN>) id 1VFfLJ-0004pQ-ER
 for submit <at> debbugs.gnu.org; Sat, 31 Aug 2013 03:11:34 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <shane.celis@HIDDEN>) id 1VFfL9-0002EI-6X
 for submit <at> debbugs.gnu.org; Sat, 31 Aug 2013 03:11:28 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM,
 T_DKIM_INVALID autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:59225)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <shane.celis@HIDDEN>) id 1VFfL9-0002EE-2f
 for submit <at> debbugs.gnu.org; Sat, 31 Aug 2013 03:11:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39554)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <shane.celis@HIDDEN>) id 1VFfL4-0005cq-1R
 for bug-guile@HIDDEN; Sat, 31 Aug 2013 03:11:23 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <shane.celis@HIDDEN>) id 1VFfKz-0002CS-2T
 for bug-guile@HIDDEN; Sat, 31 Aug 2013 03:11:17 -0400
Received: from mail-qa0-x22a.google.com ([2607:f8b0:400d:c00::22a]:33139)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <shane.celis@HIDDEN>) id 1VFfKy-0002CF-SM
 for bug-guile@HIDDEN; Sat, 31 Aug 2013 03:11:12 -0400
Received: by mail-qa0-f42.google.com with SMTP id cm18so140566qab.8
 for <bug-guile@HIDDEN>; Sat, 31 Aug 2013 00:11:12 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=from:content-type:content-transfer-encoding:subject:message-id:date
 :to:mime-version;
 bh=6fZvwfETDwhURibRdk7OxPkoEUP3KFEQi+9FlP4XDDg=;
 b=WbDHCU1pNz+RgIr6xJk8Cns2K3aOQLirLvVM+UQZb6M7g5wbdrrAsmK7sGsxpEsHUR
 FI3ZA2zAWGWfKe4Ak0FDOktDdkahcZB7/JCCqHFloTEo4s7iPOnWptzMwKeHiadUU1i3
 1dCI8u3OuUJoDDnPPTJiBqZ49qIHp099acLp28zURPiBextMu180jzG1tHbliESECtkX
 djrA4F2SAM+uWkuzqwb0zZjBVQBBwPb717GYqjdJD/Tqvqjli+0uORthpH1uLx4x7MzI
 H4pfP07+26q4tq/ilM7i69HqwRbZIurYjqEISTEdrFRXNMyW0r6xyyDXaKyORIixlln2
 GNRg==
X-Received: by 10.49.106.226 with SMTP id gx2mr15923469qeb.67.1377933072146;
 Sat, 31 Aug 2013 00:11:12 -0700 (PDT)
Received: from [192.168.1.99] (c-107-3-3-0.hsd1.vt.comcast.net. [107.3.3.0])
 by mx.google.com with ESMTPSA id q4sm3505203qah.2.1969.12.31.16.00.00
 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128);
 Sat, 31 Aug 2013 00:11:11 -0700 (PDT)
From: Shane Celis <shane.celis@HIDDEN>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: quoted-printable
Subject: Possible bug in (web server)
Message-Id: <CB238240-1C7E-4703-B8DB-733764230E5F@HIDDEN>
Date: Sat, 31 Aug 2013 03:11:10 -0400
To: bug-guile@HIDDEN
Mime-Version: 1.0 (Mac OS X Mail 6.5 \(1508\))
X-Mailer: Apple Mail (2.1508)
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -2.4 (--)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.4 (--)

Hi all,

I found a bug in (web server) on Mac OS X, and when I compared against =
GNU/Linux I seem to have found a bug in (web client) there.  I've =
included a script and further details below.

#!/usr/local/bin/guile \
-e main -s
!#
;; guile-web-server-osx-bug.scm
;;
;; This script demonstrates a possible bug in Guile's web server on
;; Mac OS X.  And it demonstrates a possible bug in Guile's web client
;; on GNU/Linux.
;;
;; Problem
;; =3D=3D=3D=3D=3D=3D=3D
;;
;; Using Guile's (web server) with an example program, I ran into the
;; following issue on Mac OS X: If I ran
;; "./guile-web-server-osx-bug.scm server" and pointed my browser at
;; http://localhost:8080, the first request would work and be
;; displayed in my browser.  The second request would timeout.  I
;; compared this with Guile on GNU/Linux and found that the (web
;; server) worked fine, but the (web client) did not seem to work.
;;
;;
;; Reproduction
;; =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
;;
;; The script takes an argument "server" or "client [hostname/ip]".
;; When run as a server, it will say hello with an incremented
;; counter.  When run as a client, it will grab a couple of known
;; sites gnu.org, fsf.org, and then try localhost or the given
;; hostname on port 8080 twice, because on Mac OS X I saw the web
;; server work on the first request but not the second. The
;; hostname/ip the client is contacting is presumed to be a Guile web
;; server on the other end but doesn't have to be.
;;
;; If there were no bugs, this script should work like this:
;; $ ./guile-web-server-osx-bug.scm server &
;; Web server replied 'Hello World! 0'.
;; Web server replied 'Hello World! 1'.
;;
;; $ ./guile-web-server-osx-bug.scm client
;; Getting http://gnu.org... response #<<response> [...]
;;
;; Getting http://fsf.org... response #<<response> [...]
;;
;; Getting http://localhost:8080... response #<<response> [...]
;;
;; Getting http://localhost:8080... response #<<response> [...]
;;
;; Mac OS X bug
;; ------------
;;
;; Info
;; ----
;;=20
;; $ uname -a
;; Darwin mbp13.local 12.4.0 Darwin Kernel Version 12.4.0: Wed May  1 =
17:57:12 PDT 2013; root:xnu-2050.24.15~1/RELEASE_X86_64 x86_64
;;
;; $ bash ./build-aux/config.guess
;; x86_64-apple-darwin12.4.0
;;
;; $ guile --version
;; guile (GNU Guile) 2.0.9 [...]
;;
;; $ ./config.status --config
;; 'LDFLAGS=3D-L/opt/local/lib' 'CPPFLAGS=3D-I/opt/local/include'
;;
;; Running
;; -------
;;=20
;; $ ./guile-web-server-osx-bug.scm server=20
;; Web server replied 'Hello World! 0'.
;;
;; --
;;
;; $ ./guile-web-server-osx-bug.scm client
;; Getting http://gnu.org... response #<<response> [...]
;;
;; Getting http://fsf.org... response #<<response> [...]
;;
;; Getting http://localhost:8080...SIGALRM called; timedout.
;;=20
;; If I try to connect to http://localhost:8080 through a web browser,
;; it does not connect; however, the web server does report that it
;; has replied.
;;
;; GNU/Linux bug
;; ------------
;;=20
;; Info
;; ----
;;
;; $ uname -a
;; Linux debian 3.2.0-4-686-pae #1 SMP Debian 3.2.46-1 i686 GNU/Linux
;;
;; $ guile --version
;; guile (GNU Guile) 2.0.9 [...]
;;
;; $ bash ./build-aux/config.guess
;; i686-pc-linux-gnu
;;
;; $ ./config.status --config
;;
;; Running
;; -------
;;
;; $ ./guile-web-server-osx-bug.scm server=20
;; Web server replied 'Hello World! 0'.
;;
;; ---
;;
;; $ ./guile-web-server-osx-bug.scm client
;; Getting http://gnu.org... response #<<response> [...]
;;
;; Getting http://fsf.org... response #<<response> [...]
;;
;; Getting http://localhost:8080...SIGALRM called; timedout.
;;
;; If I try to connect to http://localhost:8080 through a web browser,
;; it works fine; so it seems like the (web client) is not working on
;; GNU/Linux and the (web server) is not working on Mac OS X.
;;=20

(use-modules (web server)
             (web client)
             (ice-9 optargs))

(define count 0)

(define (hello-world-handler request request-body)
  (let ((reply (format #f "Hello World! ~a" count)))
    (set! count (1+ count))
    (format #t "Web server replied '~a'.~%" reply)
    (values '((content-type . (text/plain)))
            reply)))

(define (start-server)
   (run-server hello-world-handler 'http '(#:port 8080)))

(define (check-url url)
  (format #t "Getting ~a..." url)
  (format #t " response ~a~%~%" (http-get url)))

(define* (run-client #:optional (ip "localhost"))
  (alarm 10)
  ;; Test some URLs that should work.
  (check-url "http://gnu.org")
  (check-url "http://fsf.org")
  ;; Try the web server's URL now twice.
  (check-url (format #f "http://~a:8080" ip))
  (check-url (format #f "http://~a:8080" ip)))

(sigaction SIGALRM (lambda (sig)
                     (format #t "SIGALRM called; timedout.~%")
                     (exit 1)))


(define (main args)
  (unless (or (=3D 2 (length args))
              (=3D 3 (length args)))
    (format (current-error-port) "Usage: ~a <server|client [ip]>~%" (car =
args))
    (exit 2))
  (cond
   ((string=3D "server" (cadr args))
    (start-server))
   ((string=3D "client" (cadr args))
    (apply run-client (cddr args)))))





Acknowledgement sent to Shane Celis <shane.celis@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-guile@HIDDEN. Full text available.
Report forwarded to bug-guile@HIDDEN:
bug#15227; Package guile. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Mon, 25 Nov 2019 12:00:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.