c# - Avoiding first chance exception messages when the exception is safely handled -
the following bit of code catches eos exception
using (var reader = new binaryreader(httprequestbodystream)) { try { while (true) { bodybytelist.add(reader.readbyte()); } } catch (endofstreamexception) { } }
so why still receive first-chance exceptions in console?
a first chance exception of type 'system.io.endofstreamexception' occurred in mscorlib.dll
is there way hide these first chance exception messages?
the point of "first-chance" exceptions you're seeing them pre-handler can stop on them during debugging @ point of throwing. "second-chance" exception 1 has no appropriate handler. want catch "first-chance" exceptions because it's important see what's happening when it's being thrown, if catching it.
there's nothing concerned with. normal behavior.
Comments
Post a Comment