[Mono-bugs] [Bug 51281][Nor] Changed - SoapHttpClientProtocol - InvalidCastException when using custom WebResponse (works on MS.NET 1.1)

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Sat, 22 Nov 2003 01:22:44 -0500 (EST)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by rsbarro@metaverse.cc.

http://bugzilla.ximian.com/show_bug.cgi?id=51281

--- shadow/51281	2003-11-22 01:16:02.000000000 -0500
+++ shadow/51281.tmp.14913	2003-11-22 01:22:44.000000000 -0500
@@ -217,6 +217,23 @@
 }
 
 ------- Additional Comments From rsbarro@metaverse.cc  2003-11-22 01:15 -------
 Created an attachment (id=5986)
 Test Case (HelloWorldTestCase.tar.gz)
 
+
+------- Additional Comments From rsbarro@metaverse.cc  2003-11-22 01:22 -------
+I created a test case that replicates this problem.  The test case
+includes a sample Hello World web service and a client application
+that attempts to call it.  The are two "client" reference.cs files,
+one with the normal proxy class generated by VS.NET, and another
+(ReferenceNew.cs) inherits from my SoapMimeHttpClientProtocol which
+returns a custom WebResponse (MimeWebResponse).
+
+The test case has all of the code stripped out of
+SoapMimeHttpClientProtocol and MimeWebResponse, so it's easier to see
+that the
+System.Web.Services.Protocols.SoapHttpClientProtocol:ReceiveResponse
+method is choking on the fact that it's getting a class that inherits
+from System.Net.WebResponse, rather than a genuine
+System.Net.WebResponse class.  Again, this code works fine on the MS
+.NET 1.1 Framework.