Post to forum as admin bug @ mono-2.2, mojoPortal-2-2-8-2-c

mojoPortal is no longer supported on mono. This forum is here for archival purposes.

This thread is closed to new posts. You must sign in to post in the forums.
1/19/2009 9:28:52 AM
Gravatar
Total Posts 44

Post to forum as admin bug @ mono-2.2, mojoPortal-2-2-8-2-c

Created a new Forum, allowing anonymous postings:

Its possible to create a post as a guest.

If you are logged in (as Admin in my case) it fires an error:

Server Error in '/' Application
Unable to cast object of type 'System.Web.UI.Pair' to type 'System.Collections.Hashtable'.

Description: HTTP 500. Error processing request.

Stack Trace:

System.InvalidCastException: Unable to cast object of type 'System.Web.UI.Pair' to type 'System.Collections.Hashtable'.
at System.Web.UI.StateBag.LoadViewState (System.Object savedState) [0x00007] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/StateBag.cs:85
at System.Web.UI.Control.LoadViewState (System.Object savedState) [0x00006] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Control.cs:866
at System.Web.UI.Control.LoadViewStateRecursive (System.Object savedState) [0x00033] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Control.cs:1654
at System.Web.UI.Control.LoadViewStateRecursive (System.Object savedState) [0x000a2] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Control.cs:1668
at System.Web.UI.Control.LoadViewStateRecursive (System.Object savedState) [0x000a2] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Control.cs:1668
at System.Web.UI.Control.LoadViewStateRecursive (System.Object savedState) [0x000a2] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Control.cs:1668
at System.Web.UI.Control.LoadViewStateRecursive (System.Object savedState) [0x000a2] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Control.cs:1668
at System.Web.UI.Control.LoadViewStateRecursive (System.Object savedState) [0x000a2] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Control.cs:1668
at System.Web.UI.Control.LoadViewStateRecursive (System.Object savedState) [0x000a2] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Control.cs:1668
at System.Web.UI.Control.LoadViewStateRecursive (System.Object savedState) [0x000a2] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Control.cs:1668
at System.Web.UI.Page.LoadPageViewState () [0x00046] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Page.cs:1920
at System.Web.UI.Page.RestorePageState () [0x00051] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Page.cs:1552
at System.Web.UI.Page.InternalProcessRequest () [0x001b9] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Page.cs:1527
at System.Web.UI.Page.ProcessRequest (System.Web.HttpContext context) [0x0005b] in /home/installer/mono-2.2/mcs/class/System.Web/System.Web.UI/Page.cs:1347

Version information: Mono Version: 2.0.50727.1433; ASP.NET Version: 2.0.50727.1433

 

Now lets have a look at mono src class:

internal void LoadViewState (object savedState)
{
if (savedState == null)
return;

 

foreach (DictionaryEntry de in (Hashtable) savedState)
Add ((string) de.Key, de.Value);
}

internal object SaveViewState ()
{
Hashtable h = null;

foreach (DictionaryEntry de in ht) {
StateItem si = (StateItem) de.Value;
if (si.IsDirty) {
if (h == null)
h = new Hashtable ();
h.Add (de.Key, si.Value);
}
}

return h;
}

 

This seems to be symmetric, as grendel from #mono told me.

So thats not really a mono bug, or isn't it ?

 

 

1/19/2009 9:50:49 AM
Gravatar
Total Posts 18439

Re: Post to forum as admin bug @ mono-2.2, mojoPortal-2-2-8-2-c

If it behaves differnetly on .NET on windows its a Mono bug. This error does not happen on windows. If you see soemthing you think can fix it by a small change in mojoportal I'm open to that, but my instinct is its a Mono bug and should be fixed.

Best,

Joe

You must sign in to post in the forums. This thread is closed to new posts.