[Webkit-unassigned] [Bug 96201] [EFL][WK2] WKEinaSharedString needs a function to adopt eina stringshare.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Sep 11 00:21:56 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=96201





--- Comment #23 from Kenneth Rohde Christiansen <kenneth at webkit.org>  2012-09-11 00:22:18 PST ---
(In reply to comment #22)
> (In reply to comment #21)
> > (From update of attachment 163110 [details] [details])
> > View in context: https://bugs.webkit.org/attachment.cgi?id=163110&action=review
> > 
> > > Source/WebKit2/UIProcess/API/cpp/efl/WKEinaSharedString.cpp:114
> > > +{
> > > +    WKEinaSharedString sharedString;
> > > +    sharedString.m_string = static_cast<const char*>(string);
> > > +    return sharedString;
> > > +}
> > 
> > So that will copy and deallocate the local one. I suppose the copy constructor is effective :-)
> Ok~ then I'll add some private constructor that just adopt eina_stringshare, and use it.

The code is fine, I just wanted you to verify that the copying is efficient. Or if not, implement an efficient copy constructor. I guess the class only has one pointer (m_string?) so it is quite efficient

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list