On 03/19/2014 07:10 PM, Allen Zhang wrote:
Yes this makes sense. But higher debug level = more writing. Then increasing the debug level should causes more problem - because more buffering and parsing strings internally, which in turn draws on static (stack) and dynamic (heap) memory allocations - instead of hiding the problem, right?
That is logical, and is probably true in many cases.
However, it all depends on the memory allocation strategy used by the program internally, as well as on the operating system side. For instance, more logging could trigger a larger buffer allocation or different fragmentation, which could serve to mask the memory bug by not creating the circumstances that lead to an acute access violation, or not creating them in the same place or as soon.