WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
48323
[Qt] Assert in the tst_hybridPixmap::hybridPixmap() unit test.
https://bugs.webkit.org/show_bug.cgi?id=48323
Summary
[Qt] Assert in the tst_hybridPixmap::hybridPixmap() unit test.
Jocelyn Turcotte
Reported
2010-10-26 07:08:56 PDT
ASSERTION FAILED: !m_adoptionIsRequired (../../../JavaScriptCore/wtf/RefCounted.h:37 void WTF::RefCountedBase::ref())
Attachments
Patch
(1.50 KB, patch)
2010-10-26 07:13 PDT
,
Jocelyn Turcotte
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Jocelyn Turcotte
Comment 1
2010-10-26 07:13:59 PDT
Created
attachment 71877
[details]
Patch
Andreas Kling
Comment 2
2010-10-26 07:31:06 PDT
Comment on
attachment 71877
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=71877&action=review
> WebCore/bridge/qt/qt_pixmapruntime.cpp:358 > - QtPixmapInstance* instance = new QtPixmapInstance(root, data); > + RefPtr<QtPixmapInstance> instance = adoptRef(new QtPixmapInstance(root, data));
What happens with the QtPixmapInstance after this function returns? I'm asking because it was leaked previously, and createRuntimeObject() returns a member of the instance.
Kenneth Rohde Christiansen
Comment 3
2010-10-26 07:50:09 PDT
(In reply to
comment #2
)
> (From update of
attachment 71877
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=71877&action=review
> > > WebCore/bridge/qt/qt_pixmapruntime.cpp:358 > > - QtPixmapInstance* instance = new QtPixmapInstance(root, data); > > + RefPtr<QtPixmapInstance> instance = adoptRef(new QtPixmapInstance(root, data)); > > What happens with the QtPixmapInstance after this function returns? > I'm asking because it was leaked previously, and createRuntimeObject() returns a member of the instance.
You are right, it will be dereffed on return. It depends on what createRuntimeObject is doing.
Kenneth Rohde Christiansen
Comment 4
2010-10-26 09:06:30 PDT
> > WebCore/bridge/qt/qt_pixmapruntime.cpp:358 > > - QtPixmapInstance* instance = new QtPixmapInstance(root, data); > > + RefPtr<QtPixmapInstance> instance = adoptRef(new QtPixmapInstance(root, data)); > > What happens with the QtPixmapInstance after this function returns? > I'm asking because it was leaked previously, and createRuntimeObject() returns a member of the instance.
That member which is being returned is created by newRuntimeObject, but not owner by the Instance.
WebKit Commit Bot
Comment 5
2010-10-26 12:47:58 PDT
Comment on
attachment 71877
[details]
Patch Clearing flags on attachment: 71877 Committed
r70557
: <
http://trac.webkit.org/changeset/70557
>
WebKit Commit Bot
Comment 6
2010-10-26 12:48:04 PDT
All reviewed patches have been landed. Closing bug.
Ademar Reis
Comment 7
2010-10-26 13:03:59 PDT
Revision
r70557
cherry-picked into qtwebkit-2.1 with commit 12362e4 <
http://gitorious.org/webkit/qtwebkit/commit/12362e4
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug