Author: gonzalo
Date: 2005-06-26 19:20:10 -0400 (Sun, 26 Jun 2005)
New Revision: 46529
Modified:
trunk/mcs/class/System.Web/System.Web/ChangeLog
trunk/mcs/class/System.Web/System.Web/HttpContext.cs
trunk/mcs/class/System.Web/System.Web/HttpRequest.cs
trunk/mcs/class/System.Web/System.Web/HttpResponse.cs
Log:
2005-06-26 Gonzalo Paniagua Javier <[EMAIL PROTECTED]>
* HttpContext.cs:
* HttpResponse.cs:
* HttpRequest.cs: use StrUtils (invariant culture).
Modified: trunk/mcs/class/System.Web/System.Web/ChangeLog
===================================================================
--- trunk/mcs/class/System.Web/System.Web/ChangeLog 2005-06-26 23:18:41 UTC
(rev 46528)
+++ trunk/mcs/class/System.Web/System.Web/ChangeLog 2005-06-26 23:20:10 UTC
(rev 46529)
@@ -1,5 +1,11 @@
2005-06-26 Gonzalo Paniagua Javier <[EMAIL PROTECTED]>
+ * HttpContext.cs:
+ * HttpResponse.cs:
+ * HttpRequest.cs: use StrUtils (invariant culture).
+
+2005-06-26 Gonzalo Paniagua Javier <[EMAIL PROTECTED]>
+
* HttpRequest.cs: use StartsWith when looking for 'multipart/form-data'.
File uploading was broken since a few commits ago.
Modified: trunk/mcs/class/System.Web/System.Web/HttpContext.cs
===================================================================
--- trunk/mcs/class/System.Web/System.Web/HttpContext.cs 2005-06-26
23:18:41 UTC (rev 46528)
+++ trunk/mcs/class/System.Web/System.Web/HttpContext.cs 2005-06-26
23:20:10 UTC (rev 46529)
@@ -440,7 +440,7 @@
}
path = UrlUtils.Combine (Request.BaseVirtualDir, path);
- if (!path.StartsWith
(HttpRuntime.AppDomainAppVirtualPath))
+ if (!StrUtils.StartsWith (path,
HttpRuntime.AppDomainAppVirtualPath))
throw new HttpException (404, "The virtual path
'" + path +
"' maps to another
application.");
Modified: trunk/mcs/class/System.Web/System.Web/HttpRequest.cs
===================================================================
--- trunk/mcs/class/System.Web/System.Web/HttpRequest.cs 2005-06-26
23:18:41 UTC (rev 46528)
+++ trunk/mcs/class/System.Web/System.Web/HttpRequest.cs 2005-06-26
23:20:10 UTC (rev 46529)
@@ -238,7 +238,7 @@
}
_oFormData = new HttpValueCollection ();
- if (content_type.StartsWith ("multipart/form-data")) {
+ if (StrUtils.StartsWith (content_type,
"multipart/form-data")) {
MultipartContentElement [] parts =
GetMultipartFormData ();
if (parts == null)
return;
@@ -618,7 +618,8 @@
void FillPostedFiles ()
{
- if (!ContentType.StartsWith ("multipart/form-data"))
return;
+ if (!StrUtils.StartsWith (ContentType,
"multipart/form-data"))
+ return;
MultipartContentElement [] parts = GetMultipartFormData
();
if (parts == null) return;
@@ -1174,7 +1175,7 @@
}
if (!allowCrossAppMapping) {
- if (!virtualPath.ToLower ().StartsWith
(RootVirtualDir.ToLower ()))
+ if (!StrUtils.StartsWith (virtualPath,
RootVirtualDir, true))
throw new HttpException ("Mapping
across applications not allowed.");
if (RootVirtualDir.Length > 1 &&
virtualPath.Length > 1 && virtualPath [0] != '/')
Modified: trunk/mcs/class/System.Web/System.Web/HttpResponse.cs
===================================================================
--- trunk/mcs/class/System.Web/System.Web/HttpResponse.cs 2005-06-26
23:18:41 UTC (rev 46528)
+++ trunk/mcs/class/System.Web/System.Web/HttpResponse.cs 2005-06-26
23:20:10 UTC (rev 46529)
@@ -339,7 +339,7 @@
string rvd = _Context.Request.RootVirtualDir;
string basevd = rvd.Replace (app_path_mod, "");
- if (!virtualPath.StartsWith (basevd))
+ if (!StrUtils.StartsWith (virtualPath, basevd))
return virtualPath;
virtualPath = UrlUtils.Combine (rvd,
virtualPath.Substring (basevd.Length));
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches