1
Reply

Why is catch(Exception) almost always a bad idea ?

ajay singh

ajay singh

May 27, 2012
3.5k
0

    Because exceptions if they are catched in the code, you need to handle them properly. And we cannot handle all types of exceptions. Some of the exceptions we cannot deal with it and they makes the application unstable like Thread abort exception. If an exception occurs in our code, instead of supresssing it we need to fix the bug in the code. Otherwise, you will never know that an exception occurred.

    Akkiraju Ivaturi
    August 05, 2012
    0