Bug 37617 - [Qt] QScriptValue::inherits has a memory leak.
Summary: [Qt] QScriptValue::inherits has a memory leak.
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Jędrzej Nowacki
Keywords: Qt
Depends on:
Blocks: 31863
  Show dependency treegraph
Reported: 2010-04-14 15:36 PDT by Jędrzej Nowacki
Modified: 2010-04-14 20:17 PDT (History)
4 users (show)

See Also:

Fix v1 (1.51 KB, patch)
2010-04-14 15:39 PDT, Jędrzej Nowacki
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jędrzej Nowacki 2010-04-14 15:36:41 PDT
Valgrind report memory leak inside QScriptValue::inherits. 

==7532== 34 (24 direct, 10 indirect) bytes in 1 blocks are definitely lost in loss record 72 of 243                                                                                                  
==7532==    at 0x4C221A7: malloc (vg_replace_malloc.c:195)                                                                                                                                           
==7532==    by 0x50BCBC4: WTF::fastMalloc(unsigned long) (FastMalloc.cpp:249)                                                                                                                        
==7532==    by 0x5007369: WTF::FastAllocBase::operator new(unsigned long) (FastAllocBase.h:96)                                                                                                       
==7532==    by 0x50208BF: OpaqueJSString::create(unsigned short const*, unsigned int) (OpaqueJSString.h:45)                                                                                          
==7532==    by 0x502051F: JSStringCreateWithUTF8CString (JSStringRef.cpp:50)                                                                                                                         
==7532==    by 0x50026DD: QScriptConverter::toString(char const*) (qscriptconverter_p.h:63)                                                                                                          
==7532==    by 0x5004B50: QScriptValuePrivate::inherits(char const*) (qscriptvalue_p.h:765)                                                                                                          
==7532==    by 0x5003C04: QScriptValuePrivate::isError() (qscriptvalue_p.h:413)                                                                                                                      
==7532==    by 0x500212D: QScriptValue::isError() const (qscriptvalue.cpp:291)                                                                                                                       
==7532==    by 0x4064C5: tst_QScriptEngine::evaluateProgram() (tst_qscriptengine.cpp:161)                                                                                                            
==7532==    by 0x409C39: tst_QScriptEngine::qt_metacall(QMetaObject::Call, int, void**) (tst_qscriptengine.moc:90)
Comment 1 Jędrzej Nowacki 2010-04-14 15:39:04 PDT
Created attachment 53378 [details]
Fix v1
Comment 2 WebKit Commit Bot 2010-04-14 20:17:38 PDT
Comment on attachment 53378 [details]
Fix v1

Clearing flags on attachment: 53378

Committed r57628: <http://trac.webkit.org/changeset/57628>
Comment 3 WebKit Commit Bot 2010-04-14 20:17:43 PDT
All reviewed patches have been landed.  Closing bug.