2007-09-28 Marek Habersack <mhabersack@novell.com>
authorMarek Habersack <grendel@twistedcode.net>
Fri, 28 Sep 2007 08:48:51 +0000 (08:48 -0000)
committerMarek Habersack <grendel@twistedcode.net>
Fri, 28 Sep 2007 08:48:51 +0000 (08:48 -0000)
* HttpListenerRequest.cs: HasEntityBody should return false when method is GET/HEAD,
content_length is less than or equal to zero or the request is
chunked. Fixes bug #325296

svn path=/trunk/mcs/; revision=86555

mcs/class/System/System.Net/ChangeLog
mcs/class/System/System.Net/HttpListenerRequest.cs

index eb78ad0fc0110b4ea395e7fff003b18be1ca6eff..360bd05caac11fe927bd9231dff2714c8c653d2b 100644 (file)
@@ -5,6 +5,9 @@
        The DELETE method must not error out on missing Content-Length
        header (this is the behavior of the MS.NET version of the
        class). Fixes bug #323215.
+       HasEntityBody should return false when method is GET/HEAD,
+       content_length is less than or equal to zero or the request is
+       chunked. Fixes bug #325296
 
 2007-08-29  Atsushi Enomoto  <atsushi@ximian.com>
 
index 55d93ac380f50b7e142c96264e5c305be1a79b70..83d928ff67a6b0caf3cb44eab776fd88080c9788 100644 (file)
@@ -331,7 +331,7 @@ namespace System.Net {
                }
 
                public bool HasEntityBody {
-                       get { return (method == "GET" || method == "HEAD" || content_length <= 0 || is_chunked); }
+                       get { return !(method == "GET" || method == "HEAD" || content_length <= 0 || is_chunked); }
                }
 
                public NameValueCollection Headers {