[webkit-reviews] review denied: [Bug 95923] [EFL] Implement GCActivityCallback : [Attachment 202500] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue May 21 23:12:05 PDT 2013


Christophe Dumez <dchris at gmail.com> has denied Hojong Han
<hojong.han at samsung.com>'s request for review:
Bug 95923: [EFL] Implement GCActivityCallback
https://bugs.webkit.org/show_bug.cgi?id=95923

Attachment 202500: Patch
https://bugs.webkit.org/attachment.cgi?id=202500&action=review

------- Additional Comments from Christophe Dumez <dchris at gmail.com>
View in context: https://bugs.webkit.org/attachment.cgi?id=202500&action=review


> Source/JavaScriptCore/heap/HeapTimer.cpp:188
> +    return ECORE_CALLBACK_CANCEL;

You need to set heapTimer->m_timer to 0 before returning. When you return
ECORE_CALLBACK_CANCEL, the handle will become invalid and
ecore_timer_del(m_timer) will fail in the destructor.

> Source/JavaScriptCore/heap/HeapTimer.h:42
> +#include <Ecore.h>

A forward declaration of Ecore_Timer would suffice here. And this include can
be moved to the cpp.

> Source/JavaScriptCore/heap/HeapTimer.h:87
> +    void stop()

Can you put the method body in the cpp file instead?

> Source/JavaScriptCore/heap/HeapTimer.h:89
> +	   if (m_timer) {

We usually do the opposite in WebKit, return early.
If (!m_timer)
    return;

> Source/JavaScriptCore/runtime/GCActivityCallback.cpp:127
> +    m_timer = ecore_timer_add(newDelay,
reinterpret_cast<Ecore_Task_Cb>(HeapTimer::timerEvent), this);

I would add a ASSERT(!m_timer); right before this line to make sure we never
leak.


More information about the webkit-reviews mailing list