Quantcast
Channel: ASPNETWebStack Issue Tracker Rss Feed
Viewing all articles
Browse latest Browse all 7215

Created Unassigned: [WebPages]: Helper namespaces are not sanitized when the path contains special characters [1013]

$
0
0
1) Create a new ASP.NET Web Pages site
2) Under ~\App_Code\Bar, create a helper file Foo.cshtml
3) Invoke the helper from a page as Bar.Foo.SomeHelperFunction()
4) Rename the Bar folder to include a special character such as + or - or have it begin with a digit

Sample folder names:
Bar-Baz
Bar+Baz
1234Helpers

Expected:
The helper should be invoked

Actual:
A compilation error is thrown

Compiler Error Message: CS1514: { expected
namespace _ASP.Bar-Buz_ {

This is a consequence of the namespace path not being sanitized. A fix for this would involve modifying WebCodeRazorHost::DetermineNamespace to return sanitized namespaces








Viewing all articles
Browse latest Browse all 7215

Trending Articles