[Webkit-unassigned] [Bug 149496] [GTK][WPE] Use mobile user-agent on tablet

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Jul 8 01:31:06 PDT 2020


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

--- Comment #29 from Carlos Garcia Campos <cgarcia at igalia.com> ---
Comment on attachment 403599
  --> https://bugs.webkit.org/attachment.cgi?id=403599
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=403599&action=review

>>> Source/WebCore/platform/glib/UserAgentGLib.cpp:55
>>> +            g_warning("Could not open /etc/machine-info: %s", error->message);
>> 
>> This is not working, all API tests are failing because of this warning:
>> 
>> FATAL-WARNING: Could not open /etc/machine-info: Failed to open file “/etc/machine-info”: No such file or directory
> 
> Shall i remove the error again?

We should handle the right error, g_file_get_contents is not a gio function, so the error is not a G_IO_ERROR but a  G_FILE_ERROR.

>>> Source/WebCore/platform/glib/UserAgentGLib.cpp:140
>>> +static ChassisType getChassisType()
>> 
>> We don't use getFoo in WebKit when the result is returned as return value.
> 
> So just chassisType()?

Right.

>>> Source/WebCore/platform/glib/UserAgentGLib.cpp:145
>>> +    if (firstRun) {
>> 
>> Use std::once_flag
> 
> Just below WTF or in an existing file?

Since it's only used by glib, under WTF/wtf/glib I would say. See RAMSize or MemoryFootprint for examples.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20200708/7abcf1a9/attachment-0001.htm>


More information about the webkit-unassigned mailing list