Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bug in WP 7 implementation of Uri.IsWellFormedUriString?

In a .NET 4 console application, and a Silverlight 4 application, the following returns false:

Uri.IsWellFormedUriString("/test", UriKind.Absolute)

but the same call in a Windows Phone app (7.0 or 7.1 using SDK 7.1 Beta 2 published 6/29/11) returns true.

Can anyone else confirm this? Is this a bug in WP7?

Update

I reported this as a bug on Microsoft Connect and received an update today that it has been closed as "Wont' Fix". This doesn't matter to me but I thought I would add this update just as an FYI.

like image 640
Jeff Ogata Avatar asked Aug 08 '11 02:08

Jeff Ogata


1 Answers

After the documentation its a bug:

A Boolean value that is true if the string was well-formed in accordance with RFC 3986; else false.

And the RFC 3986 says:

absolute-URI = scheme ":" hier-part [ "?" query ]

So better submit this bug on Microsoft Connect under VS referencing the Tooling Version for phone development tools.

like image 50
Skomski Avatar answered Oct 23 '22 04:10

Skomski