Bug 14809 - Visual Studio crashes when Windows is hibernated, due to an unhandled exception
Summary: Visual Studio crashes when Windows is hibernated, due to an unhandled exception
Status: VERIFIED FIXED
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: General ()
Version: 1.12.x
Hardware: PC Windows
: Low normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2013-09-17 12:20 UTC by Jon Goldberger [MSFT]
Modified: 2015-07-27 14:02 UTC (History)
4 users (show)

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


Attachments
Log Files (158.67 KB, application/zip)
2013-09-17 12:20 UTC, Jon Goldberger [MSFT]
Details


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 Jon Goldberger [MSFT] 2013-09-17 12:20:58 UTC
Created attachment 4913 [details]
Log Files

I often hibernate my laptop with Visual Studio still running. If I do 
this while a Xamarin.Android project is open, Visual Studio will crash 
when the computer is resumed, and an unhandled exception is logged in 
the event log. This is annoying, as I lose my place in what I was 
working on.

Application: devenv.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.ArgumentNullException
Stack:
at System.String.Format(System.String, System.Object[])
at Xamarin.AndroidDesigner.JavaProcessConnection.javaProcess_OutputDataReceived(System.Object, System.Diagnostics.DataReceivedEventArgs)
at System.Diagnostics.Process.OutputReadNotifyUser(System.String)
at System.Diagnostics.AsyncStreamReader.FlushMessageQueue()
at System.Diagnostics.AsyncStreamReader.ReadBuffer(System.IAsyncResult)
at System.IO.Stream+ReadWriteTask.InvokeAsyncCallback(System.Object)
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.IO.Stream+ReadWriteTask.System.Threading.Tasks.ITaskCompletionAction.Invoke(System.Threading.Tasks.Task)
at System.Threading.Tasks.Task.FinishContinuations()
at System.Threading.Tasks.Task.FinishStageThree()
at System.Threading.Tasks.Task.FinishStageTwo()
at System.Threading.Tasks.Task.Finish(Boolean)
at System.Threading.Tasks.Task.ExecuteWithThreadLocal(System.Threading.Tasks.Task ByRef)
at System.Threading.Tasks.Task.ExecuteEntry(Boolean)
at System.Threading.Tasks.Task.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()

This is followed by another exception in the event log, which may or may 
not be related:

Error Handler Exception: System.ServiceModel.CommunicationException: There was an error reading from the pipe: Unrecognized error 109 (0x6d). ---> System.IO.IOException: The read operation failed, see inner exception. ---> System.ServiceModel.CommunicationException: There was an error reading from the pipe: Unrecognized error 109 (0x6d). ---> System.IO.PipeException: There was an error reading from the pipe: Unrecognized error 109 (0x6d).
at System.ServiceModel.Channels.PipeConnection.OnAsyncReadComplete(Boolean haveResult, Int32 error, Int32 numBytes)
--- End of inner exception stack trace ---
at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result)
at System.ServiceModel.Channels.ConnectionStream.EndRead(IAsyncResult asyncResult)
at System.Net.FixedSizeReader.ReadCallback(IAsyncResult transportResult)
--- End of inner exception stack trace ---
at System.Net.Security.NegotiateStream.EndRead(IAsyncResult asyncResult)
at System.ServiceModel.Channels.StreamConnection.EndRead()
--- End of inner exception stack trace ---
at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result)
at System.ServiceModel.Channels.TransportDuplexSessionChannel.EndTryReceive(IAsyncResult result, Message& message)
at System.ServiceModel.Dispatcher.DuplexChannelBinder.EndTryReceive(IAsyncResult result, RequestContext& requestContext)
at System.ServiceModel.Dispatcher.ErrorHandlingReceiver.EndTryReceive(IAsyncResult result, RequestContext& requestContext)
at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result)
at System.ServiceModel.Channels.TransportDuplexSessionChannel.EndTryReceive(IAsyncResult result, Message& message)
at System.ServiceModel.Dispatcher.DuplexChannelBinder.EndTryReceive(IAsyncResult result, RequestContext& requestContext)
at System.ServiceModel.Dispatcher.ErrorHandlingReceiver.EndTryReceive(IAsyncResult result, RequestContext& requestContext)

=====================================================================================================================

Version info:
Microsoft Visual Studio Professional 2012
Version 11.0.60610.01 Update 3
Microsoft .NET Framework
Version 4.5.50709

Installed Version: Professional

LightSwitch for Visual Studio 2012   04938-004-0033001-02566
Microsoft LightSwitch for Visual Studio 2012

Team Explorer for Visual Studio 2012   04938-004-0033001-02566
Microsoft Team Explorer for Visual Studio 2012

Visual Basic 2012   04938-004-0033001-02566
Microsoft Visual Basic 2012

Visual C# 2012   04938-004-0033001-02566
Microsoft Visual C# 2012

Visual C++ 2012   04938-004-0033001-02566
Microsoft Visual C++ 2012

Visual F# 2012   04938-004-0033001-02566
Microsoft Visual F# 2012

Visual Studio 2012 Code Analysis Spell Checker   04938-004-0033001-02566
Microsoft® Visual Studio® 2012 Code Analysis Spell Checker

Portions of International CorrectSpell™ spelling correction system © 1993 by Lernout & Hauspie Speech Products N.V. All rights reserved.

The American Heritage® Dictionary of the English Language, Third Edition Copyright © 1992 Houghton Mifflin Company. Electronic version licensed from Lernout & Hauspie Speech Products N.V. All rights reserved.

Windows Phone SDK 8.0 - ENU   04938-004-0033001-02566
Windows Phone SDK 8.0 - ENU

Cobisi.RoutingAssistant   1.0
http://cobisi.com

Color Theme Designer   1.0
Designer for creating new color themes

IdentityAndAccessVSPackage   1.0
Identity and Access VS Package

JetBrains dotCover 2.5   Full Edition build 2.5.574.60 on 2013-09-04T12:55:00
JetBrains dotCover 2.5 package for Microsoft Visual Studio. For more information about dotCover, visit http://www.jetbrains.com/dotcover/. Copyright © 2009–2013 JetBrains, Inc.

JetBrains ReSharper 8.0.1   C# Edition build 8.0.1000.2286 on 2013-09-04T21:18:00
JetBrains ReSharper 8.0.1 package for Microsoft Visual Studio. For more information about ReSharper, visit http://www.jetbrains.com/resharper/. Copyright © 2003–2013 JetBrains, Inc.

jslint.VS2012   1.0
Adds JSLlint support into Visual Studio

Microsoft .NET Micro Framework v4.3   
Microsoft .NET Micro Framework SDK v4.3
Version 4.3.0.0

Microsoft Advertising SDK for Windows Phone   6.2.923.0
Microsoft Advertising SDK for Windows Phone
Build 6.2.923.0

Microsoft XNA Game Studio   4.0
Microsoft XNA Game Studio 4.0
Build 4.0.40906.0

Node.js Tools for Visual Studio   0.1
Provides support for editing and debugging node.js applications.

NuGet Package Manager   2.7.40808.167
NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.

PowerGUIExt   1.0
PowerGUI integrated into Visual Studio.

PreEmptive Analytics Visualizer   1.0
Microsoft Visual Studio extension to visualize aggregated summaries from the PreEmptive Analytics product.

SQL Server Data Tools   11.1.20627.00
Microsoft SQL Server Data Tools

Visual Studio 11 Editor Extension   1.0
Information about my package

VisualSVN   3.5.0
Integration with Subversion version control. For more information about VisualSVN, see the VisualSVN website at http://www.visualsvn.com
Copyright © 2005-2013 VisualSVN Ltd. All rights reserved.

VSColorOutput   1.4.3
Color output for build and debug windows - http://blueonionsoftware.com/vscoloroutput.aspx

Web Developer Tools   1.2.40308.0
Microsoft Web Developer Tools contains the following components:
Page Inspector: Tool that offers an efficient way to decompose Web Applications and diagnose front-end issues.
Web Publishing: Extensions required for Web Publishing for both hosted servers as well as on premises.
Web Form Templates: Includes the default templates for Web Form Applications.
Editor Extensions: Includes HTML, CSS, and JS editor extensions that greatly enhance the development experience.

Xamarin.Android   4.8.01013 (b76e8ec4)
Visual Studio plugin to enable development for Xamarin.Android.

Xamarin.iOS   1.3.250 (49348a51)
Visual Studio extension to enable development for Xamarin.iOS

VMDebugger
For more information about VMware, Inc., see their website at
http://www.vmware.com
Copyright (c) 2012 VMware, Inc.
Comment 3 PJ 2013-11-19 16:38:26 UTC
This bug was targeted for a past milestone, moving to the next active non-hotfix milestone.
Comment 4 Rajneesh Kumar 2015-07-27 14:01:53 UTC
I have checked this issue with the latest stable build XVS 3.11.666 and observed that this issue has been fixed and no longer exist with this build. I observed that on hibernating system when Xamarin.Android project is open, and Visual Studio does't crash when the computer is resumed, also VS resumed successfully without any exception.

Please refer the screencast: http://www.screencast.com/t/SIcZaDTBxFK

This issue has been fixed, hence I am closing this issue.

Thanks..!

Environment Info:

Microsoft Visual Studio Professional 2013
Version 12.0.31101.00 Update 4
Microsoft .NET Framework
Version 4.5.50938
Installed Version: Professional
Xamarin   3.11.666.0 (ebae43a)
Visual Studio extension to enable development for Xamarin.iOS and
Xamarin.Android.
Xamarin.Android   5.1.4.16 (5f55a9ef61c11b6ce0890bc91e4c71b1b92be214)
Visual Studio plugin to enable development for Xamarin.Android.
Xamarin.iOS   8.10.2.0 (67b390d0d1bd741582cf7b7fd3ffea08583a3f83)
Visual Studio extension to enable development for Xamarin.iOS.