RESOLVED FIXED Bug 37598
[Qt] tst_QScriptValue::toString has a memory leak.
https://bugs.webkit.org/show_bug.cgi?id=37598
Summary [Qt] tst_QScriptValue::toString has a memory leak.
Jędrzej Nowacki
Reported 2010-04-14 12:57:28 PDT
Valgrind report a memory leak inside the QScriptValue::toString autotest. It seems that a temporary variable is not released. ==5038== at 0x4C221A7: malloc (vg_replace_malloc.c:195) ==5038== by 0x50BCB38: WTF::fastMalloc(unsigned long) (FastMalloc.cpp:249) ==5038== by 0x50072DD: WTF::FastAllocBase::operator new(unsigned long) (FastAllocBase.h:96) ==5038== by 0x5020833: OpaqueJSString::create(unsigned short const*, unsigned int) (OpaqueJSString.h:45) ==5038== by 0x5020493: JSStringCreateWithUTF8CString (JSStringRef.cpp:50) ==5038== by 0x4FFFF34: QScriptConverter::toString(QString const&) (qscriptconverter_p.h:59) ==5038== by 0x50000C1: QScriptEnginePrivate::makeJSValue(QString const&) const (qscriptengine_p.h:112) ==5038== by 0x50036C1: QScriptValuePrivate::QScriptValuePrivate(QScriptEngine const*, QString const&) (qscriptvalue_p.h:284) ==5038== by 0x5001CE1: QScriptValue::QScriptValue(QScriptEngine*, QString const&) (qscriptvalue.cpp:162) ==5038== by 0x414952: tst_QScriptValue::initScriptValues() (tst_qscriptvalue_generated.cpp:112) ==5038== by 0x41F8CC: tst_QScriptValue::toString_initData() (tst_qscriptvalue_generated.cpp:667) ==5038== by 0x405C0E: tst_QScriptValue::dataHelper(void (tst_QScriptValue::*)(), void (tst_QScriptValue::*)(char const*)) (tst_qscriptvalue.cpp:36)
Attachments
Fix v1 (1.47 KB, patch)
2010-04-14 13:36 PDT, Jędrzej Nowacki
no flags
Jędrzej Nowacki
Comment 1 2010-04-14 13:36:44 PDT
WebKit Commit Bot
Comment 2 2010-04-14 19:58:21 PDT
Comment on attachment 53360 [details] Fix v1 Clearing flags on attachment: 53360 Committed r57625: <http://trac.webkit.org/changeset/57625>
WebKit Commit Bot
Comment 3 2010-04-14 19:58:26 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.