In PluginProcessProxy::scanPlugin -> ASSERT(lines.size() == 3)
Created attachment 182331 [details]
Comment on attachment 182331 [details]
View in context: https://bugs.webkit.org/attachment.cgi?id=182331&action=review
> + String result = newLength == oldLength + 1 ? stringBuffer : String(stringBuffer.characters16(), newLength);
I think a if() else would read better. I don't really mind either if you keep this.
> + ASSERT(result.endsWith(UChar('\n')));
You should not have to cast to UChar here. If you get a warning without the cast, let's fix WTFString instead.
> - ASSERT(lines.size() == 3);
> + ASSERT(lines.size() == 4 && lines.last().isEmpty());
Looks sane. I trust you on the output.
Thanks for the quick review!
> > Source/WebKit2/Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:176
> > + ASSERT(result.endsWith(UChar('\n')));
> You should not have to cast to UChar here. If you get a warning without the cast, let's fix WTFString instead.
Hm, I'm not sure about how to do this. Using the UChar version has the implicit assumption that it is a 16 bit string. So, should we allow an LChar version only 8 for bit strings, or both? I would rather postpone this to a follow-up.
Landed in http://trac.webkit.org/changeset/139600