Bug 2640 - Clicking "Clear" on "Android Device Logging" crashes Visual Studio 2010
Summary: Clicking "Clear" on "Android Device Logging" crashes Visual Studio 2010
Status: VERIFIED FIXED
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: Android ()
Version: unspecified
Hardware: PC Windows
: High normal
Target Milestone: ---
Assignee: dean.ellis
URL:
: 10956 ()
Depends on:
Blocks:
 
Reported: 2011-12-25 20:04 UTC by frankhevans
Modified: 2016-08-03 15:22 UTC (History)
13 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
VERIFIED FIXED

Description frankhevans 2011-12-25 20:04:34 UTC
Visual Studio crashes when I click the "Clear" button for the "Android Device Logging". 

This is happening when I am connected to a physical android device (not emulator). This also happens when the device is NOT connected (log is empty).

It seems to happen more frequently if no device is connected, or if the log is empty.
Comment 1 Conor O'Doherty 2012-11-06 09:22:05 UTC
Clicking "Toggle Errors" crashes VS 2010. This problem happens continiously and is very obvious.

Note: If you stop logging while toggling sometimes alleviates the problem.
Comment 2 Joshua Barker 2013-03-05 09:53:10 UTC
Also crashing in VS2012 when toggling errors

Application: devenv.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.NullReferenceException
Stack:
   at System.Windows.Forms.ListView+ListViewNativeItemCollection.get_Item(Int32)
   at System.Windows.Forms.ListView+ListViewItemCollection.get_Item(Int32)
   at System.Windows.Forms.ListView.GetItemAt(Int32, Int32)
   at System.Windows.Forms.ListView.OnMouseHover(System.EventArgs)
   at System.Windows.Forms.ListView.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.OnMessage(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr, Int32, IntPtr, IntPtr)

and

Application: devenv.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.NullReferenceException
Stack:
   at System.Windows.Forms.ListView+ListViewNativeItemCollection.get_Item(Int32)
   at System.Windows.Forms.ListView+ListViewItemCollection.get_Item(Int32)
   at System.Windows.Forms.ListView.set_VirtualListSize(Int32)
   at Mono.Android.VisualStudio.LogCatControl.UpdateView(System.String)
   at Mono.Android.VisualStudio.LogCatControl.cmdFilterErrors_Click(System.Object, System.EventArgs)
   at System.Windows.Forms.ToolStripItem.RaiseEvent(System.Object, System.EventArgs)
   at System.Windows.Forms.ToolStripButton.OnClick(System.EventArgs)
   at System.Windows.Forms.ToolStripItem.HandleClick(System.EventArgs)
   at System.Windows.Forms.ToolStripItem.HandleMouseUp(System.Windows.Forms.MouseEventArgs)
   at System.Windows.Forms.ToolStripItem.FireEventInteractive(System.EventArgs, System.Windows.Forms.ToolStripItemEventType)
   at System.Windows.Forms.ToolStripItem.FireEvent(System.EventArgs, System.Windows.Forms.ToolStripItemEventType)
   at System.Windows.Forms.ToolStrip.OnMouseUp(System.Windows.Forms.MouseEventArgs)
   at System.Windows.Forms.Control.WmMouseUp(System.Windows.Forms.Message ByRef, System.Windows.Forms.MouseButtons, Int32)
   at System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.ScrollableControl.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.ToolStrip.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.OnMessage(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.Control+ControlNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr, Int32, IntPtr, IntPtr)
Comment 4 dean.ellis 2013-11-14 08:41:11 UTC
I have managed to replicate this issue.

As a result a number of improvements and fixes have not been made to the log viewer. The code will need to go through testing and be scheduled for the next major release.
Comment 5 dean.ellis 2013-11-20 03:33:40 UTC
*** Bug 10956 has been marked as a duplicate of this bug. ***
Comment 6 Saurabh 2013-12-02 13:07:42 UTC
Today, we have checked this issue with latest build:

VS 2010
X.Android 4.10.02005

Now, on clicking 'Clear' on "Android Device Logging" VS does not crash.
Screencast: http://screencast.com/t/Uwa91DmRQ

Closing this issue.