Bug 18570 - Break when an exception doesn't honor selection
Summary: Break when an exception doesn't honor selection
Status: RESOLVED FIXED
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: Android ()
Version: 3.0
Hardware: PC Windows
: --- normal
Target Milestone: ---
Assignee: vsx
URL:
Depends on:
Blocks:
 
Reported: 2014-03-25 09:26 UTC by Miha Markic
Modified: 2016-12-22 18:33 UTC (History)
5 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:
RESOLVED FIXED

Description Miha Markic 2014-03-25 09:26:33 UTC
This code:
try
{
    throw new CryptographicException();
}
catch (Exception ex)
{
}

When I set Visual Studio 2013 to break on all "Common Language Runtime Exceptions" it works as it should-it stops at throw statement. And it works correctly when I set *only System.Security.Cryptography namespace or only CryptographicException. That's fine.
However, if I set all "Common Language Runtime Exceptions" and clear CryptographicException or entire System.Security.Cryptography namespace then the execution will still stop at throw keyword which is incorrect.

TL;DR when I filter out an exception Visual Studio still stops.
Comment 1 Ram Chandra 2014-03-25 10:42:09 UTC
I tried to reproduce this issue and I am able to reproduce this issue.

Steps to reproduce :
Part I:
1. Create an "Android Application" on "visual studio 2013".
2. Paste the following code on"onCreate" method of  "Activity.cs" class.
      try
      {
             throw new CryptographicException();
      }
     catch (Exception ex)
     {
     }
3. Navigate to Debug -> Exceptions.
4. Check all check box  "Common Language Runtime Exceptions" option in exception dialog.
5. Build and run the application.
6. Program control stops at throw statement.

Part II:
1. Uncheck all checkbox of "Common Language Runtime Exceptions" option.
2. Check only  "System.Security.Cryptography" check box from "Common Language Runtime Exceptions" option.
3. Build and run the application.
4. Program control stops at throw statement.

Part III:
1. Check all checkbox of "Common Language Runtime Exceptions" option.
2. Uncheck only  "System.Security.Cryptography" check box from "Common Language Runtime Exceptions" option.
3. Build and run the application.
4. Program control stops at throw statement.

I observed that in all three cases (Part I, Part II, Part III) program control stops at throw statement i.e "throw new CryptographicException();"

Screencast: http://screencast.com/t/Muno2Un0THAR

Environment Info:

Windows 8
Visual Studio 2013
Xamarin.Android: 4.12.0.2
Comment 2 Rajneesh Kumar 2015-07-15 07:17:38 UTC
I have checked this issue with the latest stable build XVS 3.11.666 and
observed that this issue still exist with this build. I observed that if I set all "Common Language Runtime Exceptions" and clear CryptographicException or entire System.Security.Cryptography namespace then the execution will still stop at throw new CryptographicException();

Screencast: http://www.screencast.com/t/UpkcyJHs

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.
Comment 3 Emanuel 2016-12-22 18:33:36 UTC
Hi,
This issue was fixed in C8, so you can check it in our latest stable. 
I'll mark the bug as resolved fixed.
Please feel free to reopen it if you can still reproduce the issue with current bits.
Thanks!