[Webkit-unassigned] [Bug 93255] [GTK] Webkit 1.8.2 fails to build with MinGW with spellchecking enabled

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Sep 23 06:08:48 PDT 2012


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





--- Comment #7 from Kalev Lember <kalevlember at gmail.com>  2012-09-23 06:09:16 PST ---
(In reply to comment #6)
> > Source/WebKit/gtk/WebCoreSupport/TextCheckerClientGtk.cpp:64
> > -    GOwnPtr<gchar> utf8Text(g_utf16_to_utf8(const_cast<gunichar2*>(text), length, 0, 0, 0));
> > +    GOwnPtr<gchar> utf8Text(g_utf16_to_utf8(reinterpret_cast<const gunichar2*>(text), length, 0, 0, 0));
> 
> I mentioned this to pfor via IRC, but I'll leave it here for posterity: I think it might be necessary here to use  g_ucs4_to_utf8 instead of simply casting 32-bit characters to 16-bit.

I don't think the cast actually loses precision. It is from UChar* to gunichar2*; I believe these are both always defined as 16 bit types.



More information about the webkit-unassigned mailing list