What is the best exception handling strategy within error logging classes?
问题 I am writing an error logging set of classes which will log to file, event log etc. What exception handling should be performed within these classes? For instance, say I have a LogError method, which is called from exception handlers, and writes to file. What is considered the best thing to do, should an error occur? Obviously, I should make these methods as fail safe as possible, but problems can always occur. 回答1: Generally I output to stderr as much information as possible in that case,