Details
-
Task
-
Resolution: Invalid
-
P3: Somewhat important
-
None
-
None
-
Windows
Description
A report has been made that the following code will flag Microsoft debugging extensions to output memory leak warnings:
#include <QtGui/QApplication> #include <QWebView> #include <QtCore/QTimer> #define _CRTDBG_MAP_ALLOC #include <crtdbg.h> int main(int argc, char *argv[]) { _CrtSetDbgFlag ( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF ); QApplication a(argc, argv); QWebView webView; QUrl url("http://qt.nokia.com"); // The following line leads to memory leaks, see VS output window webView.setUrl(url); QTimer::singleShot( 100, QApplication::instance(), SLOT(quit())); return a.exec(); }
No warnings were observed with the MS debug detection, however, running the example using Purify on Windows XP revealed some potential problems (if the leak in MSVCRT and other parts of the MS C runtime are ignored).
The purify text report is attached. Please validate the reported leak in QtWebkit and QUdpSocket and the potential leaks in other components.