Author: mhabersack
Date: 2007-09-05 16:53:09 -0400 (Wed, 05 Sep 2007)
New Revision: 85381

Modified:
   trunk/mcs/class/System/System/ChangeLog
   trunk/mcs/class/System/System/UriTypeConverter.cs
Log:
2007-09-05  Marek Habersack  <[EMAIL PROTECTED]>

            * UriTypeConverter.cs: conversion from string should be possible
            for both relative and absolute URIs.
            Conversion to a string or an InstanceDescriptor must not assume
            that the uri is absolute.


Modified: trunk/mcs/class/System/System/ChangeLog
===================================================================
--- trunk/mcs/class/System/System/ChangeLog     2007-09-05 20:44:15 UTC (rev 
85380)
+++ trunk/mcs/class/System/System/ChangeLog     2007-09-05 20:53:09 UTC (rev 
85381)
@@ -2,6 +2,8 @@
 
        * UriTypeConverter.cs: conversion from string should be possible
        for both relative and absolute URIs.
+       Conversion to a string or an InstanceDescriptor must not assume
+       that the uri is absolute.
 
 2007-08-01  Atsushi Enomoto  <[EMAIL PROTECTED]>
 

Modified: trunk/mcs/class/System/System/UriTypeConverter.cs
===================================================================
--- trunk/mcs/class/System/System/UriTypeConverter.cs   2007-09-05 20:44:15 UTC 
(rev 85380)
+++ trunk/mcs/class/System/System/UriTypeConverter.cs   2007-09-05 20:53:09 UTC 
(rev 85381)
@@ -98,12 +98,12 @@
                        Uri uri = (value as Uri);
                        if (uri != null) {
                                if (destinationType == typeof (string))
-                                       return uri.AbsoluteUri;
+                                       return uri.ToString ();
                                if (destinationType == typeof (Uri))
                                        return uri;
                                if (destinationType == typeof 
(InstanceDescriptor)) {
                                        ConstructorInfo ci = typeof 
(Uri).GetConstructor (new Type [1] { typeof (string) });
-                                       return new InstanceDescriptor (ci , new 
object [] { uri.AbsoluteUri });
+                                       return new InstanceDescriptor (ci , new 
object [] { uri.ToString ()});
                                }
                        }
 

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to