[Mono-bugs] [Bug 77520][Nor] Changed - TcpChannel.Parse returns
incorrect objectURI
bugzilla-daemon at bugzilla.ximian.com
bugzilla-daemon at bugzilla.ximian.com
Thu Feb 16 16:07:40 EST 2006
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 robertj at gmx.net.
http://bugzilla.ximian.com/show_bug.cgi?id=77520
--- shadow/77520 2006-02-16 07:52:37.000000000 -0500
+++ shadow/77520.tmp.12324 2006-02-16 16:07:40.000000000 -0500
@@ -41,6 +41,76 @@
------- Additional Comments From lluis at ximian.com 2006-02-16 07:52 -------
> This causes client-activated binary remoting to fail on
> linux when RemotingConfiguration.ApplicationName is assigned.
Can you please provide a test app I can use to reproduce this failure?
Thanks.
+
+------- Additional Comments From robertj at gmx.net 2006-02-16 16:07 -------
+I already have a test case for this:
+
+using System;
+using System.Reflection;
+using System.Runtime.Remoting;
+using System.Runtime.Remoting.Messaging;
+using System.Runtime.Remoting.Channels;
+using System.Runtime.Remoting.Channels.Tcp;
+using System.Runtime.Remoting.Channels.Http;
+
+class Test
+{
+ static void Main ()
+ {
+ RemotingConfiguration.ApplicationName = "foo";
+ TcpChannel tc = new TcpChannel (0);
+ HttpChannel hc = new HttpChannel (0);
+
+ TestParse (tc, "tcp://localhost:1234/foo/object.rem");
+ TestParse (tc, "tcp://localhost:1234/object.rem");
+ TestParse (tc, "tcp://localhost:1234/foo/");
+ TestParse (tc, "tcp://localhost:1234/foo");
+ TestParse (tc, "tcp://localhost:1234");
+
+ TestParse (hc, "http://localhost:1234/foo/object.rem");
+ TestParse (hc, "http://localhost:1234/object.rem");
+ TestParse (hc, "http://localhost:1234/foo/");
+ TestParse (hc, "http://localhost:1234/foo");
+ TestParse (hc, "http://localhost:1234");
+ }
+
+ static void TestParse (IChannel chan, string url)
+ {
+ string objectUri;
+ string channelUrl = chan.Parse (url, out objectUri);
+ if (channelUrl != null)
+ Console.WriteLine ("{0} {1}", channelUrl,
+ objectUri == null ? "null" : objectUri);
+ }
+}
+
+
+Output of MS.NET 1.1:
+====================
+tcp://localhost:1234 /foo/object.rem
+tcp://localhost:1234 /object.rem
+tcp://localhost:1234 /foo/
+tcp://localhost:1234 /foo
+tcp://localhost:1234 null
+http://localhost:1234 /foo/object.rem
+http://localhost:1234 /object.rem
+http://localhost:1234 /foo/
+http://localhost:1234 /foo
+http://localhost:1234 null
+
+Output of Mono HEAD
+===================
+tcp://localhost:1234 foo/object.rem
+tcp://localhost:1234 object.rem
+tcp://localhost:1234 foo/
+tcp://localhost:1234 foo
+tcp://localhost:1234 null
+http://localhost:1234 /foo/object.rem
+http://localhost:1234 /object.rem
+http://localhost:1234 /foo/
+http://localhost:1234 /foo
+http://localhost:1234 null
+
More information about the mono-bugs
mailing list