<div dir="ltr">Hi all,<div><br></div><div>I met a crash when trying to start a .net 4.0 application compiled on Windows. </div><div><br></div><div>The application named PAT and can be download here. </div><div> <br clear="all">
<div>When I tried <span style="font-family:arial,sans-serif;font-size:13.63636302947998px">$ mono PAT\ 3.exe</span></div><div><span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><br></span></div><div>
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">it showed the following results:</span></div><div><span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.ArgumentException: A null reference or invalid value was found</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">[GDI+ status: InvalidParameter]</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Drawing.GDIPlus.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">CheckStatus (Status status) [0x00000] in</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Drawing.Drawing2D.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">LinearGradientBrush..ctor (Rectangle</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">rect, Color color1, Color color2, LinearGradientMode</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">linearGradientMode) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at (wrapper remoting-invoke-with-check)</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.Drawing.Drawing2D.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">LinearGradientBrush:.ctor</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Drawing.Rectangle,</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.Drawing.Color,System.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">Drawing.Color,System.Drawing.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">Drawing2D.LinearGradientMode)</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripProfessionalRenderer.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">OnRenderToolStripPanelBackgrou</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">nd</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripPanelRenderEventArgs e) [0x00000] in</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripRenderer.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">DrawToolStripPanelBackground</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripPanelRenderEventArgs e) [0x00000] in</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripPanel.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">OnPaintBackground</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">PaintEventArgs e) [0x00000] in <filename</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.Control.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">WmPaint</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.Message& m) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.Control.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">WndProc</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.Message& m) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ScrollableControl.WndProc</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.Message& m) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ContainerControl.WndProc</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.Message& m) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.Control+</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ControlWindowTarget.OnMessage</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.Message& m) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.Control+</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ControlNativeWindow.WndProc</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.Message& m) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">NativeWindow.WndProc (IntPtr hWnd, Msg msg,</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">IntPtr wParam, IntPtr lParam) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">Unhandled Exception:</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.ArgumentException: A null reference or invalid value was found</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">[GDI+ status: InvalidParameter]</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Drawing.GDIPlus.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">CheckStatus (Status status) [0x00000] in</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Drawing.Graphics.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">GdipMeasureString (IntPtr graphics,</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.String text, System.Drawing.Font font,</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.Drawing.RectangleF& layoutRect, IntPtr stringFormat) [0x00000]</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Drawing.Graphics.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">MeasureString (System.String text,</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.Drawing.Font font, Int32 width, System.Drawing.StringFormat</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">format) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at (wrapper remoting-invoke-with-check)</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.Drawing.Graphics:</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">MeasureString</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(string,System.Drawing.Font,</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">int,System.Drawing.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">StringFormat)</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">TextRenderer.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">MeasureTextInternal</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(IDeviceContext dc, System.String text, System.Drawing.Font font, Size</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">proposedSize, TextFormatFlags flags, Boolean useMeasureString)</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">[0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">TextRenderer.MeasureText (System.String</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">text, System.Drawing.Font font, Size proposedSize, TextFormatFlags</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">flags) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripItem.OnParentChanged</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStrip oldParent,</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.Windows.Forms.ToolStrip newParent) [0x00000] in <filename</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripItem.set_Parent</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStrip value) [0x00000] in <filename</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at (wrapper remoting-invoke-with-check)</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripItem:set_Parent</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStrip)</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripItemCollection.Remove</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">(System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripItem value) [0x00000] in <filename</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripItem.Dispose (Boolean disposing)</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">[0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripDropDownItem.Dispose (Boolean</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">disposing) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.Windows.Forms.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">ToolStripMenuItem.Dispose (Boolean</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px">disposing) [0x00000] in <filename unknown>:0</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px"><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">  at System.ComponentModel.</span><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">Component.Finalize () [0x00000] in</span><br style="font-family:arial,sans-serif;font-size:13.63636302947998px">
<span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><filename unknown>:0</span><br></div><div><span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><br>
</span></div><div><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">Can anyone give some hints on this issue?</span></div><div><span style="font-family:arial,sans-serif;font-size:13.63636302947998px"><br>
</span></div><div><span style="font-family:arial,sans-serif;font-size:13.63636302947998px">Thanks very much.</span></div><div><br></div>-- <br><div>Best Regards, </div><div>Ji Kun</div><div><br></div><div><br></div><div><br>
</div>
</div></div>