CDumpContext::operator<<(LPCTSTR) causes an Access Violation (bug?)

A

Andrew Burlak

Hi,

The following code is now terribly broken when compiled with 7.1:

afxDump << _T("%s%s%s%s%s%s");

It was OK in VC 6, now it causes AV.
The problem is that CDumpContext::OutputString(LPCTSTR lpsz) method passes
the 'lpsz' parameter to a TRACE macro:

TRACE(traceDumpContext, 0, lpsz);

which is just wrong. It should be:

TRACE(traceDumpContext, 0, _T("%s"), lpsz);

I suppose it is quite a critical bug in MFC 7.1.
Is it going to be fixed?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top