[Mono-dev] Patches for mono-winforms

Stifu stifu at free.fr
Sat Aug 18 20:48:54 UTC 2012


The OneIdlePerThread test does not seem to run on Windows, for some reason.
It doesn't fail, but it doesn't run... Therefore, maybe it shouldn't pass on
Linux.


Steven Boswell II wrote
> 
> https://github.com/mono/mono/commit/38bdbad5071487a11f4330077c383375dce39840
> 
> 
> This change introduced a OneIdlePerThread unit test that has never worked
> for me.  All I get is the following exception:
> 
> System.InvalidOperationException : Cannot call Invoke or BeginInvoke on a
> control until the window handle is created
> 
> 
> Patch #18 fixes that by creating a Form type that calls CreateHandle() in
> its constructor.  But now the unit test hangs hard in Mono!
> 
> I created a project with the unit-test, and when run in Mono, it hangs
> hard; selecting "Run -> Pause" in MonoDevelop hangs MonoDevelop, and the
> debugged process chews up 100% of the CPU time
> 
> I ran the project in .NET, and instead of a hang, I get this exception:
> 
> System.InvalidOperationException: Cross-threaded operation not valid:
> Control '' accessed from a thread other than the thread it was created on.
> 
> Patch #18a fixes that by moving the creation of form2 into the right
> thread.  Now the unit test passes.
> 
> So patch #18a can be checked in, but note that patch #18 demonstrates that
> Mono hangs in a situation where .NET throws an exception.
> 
> Steven Boswell
> 
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at .ximian
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
> 



--
View this message in context: http://mono.1490590.n4.nabble.com/Patches-for-mono-winforms-tp4650627p4656311.html
Sent from the Mono - Dev mailing list archive at Nabble.com.


More information about the Mono-devel-list mailing list