Bug 162613 - [GTK] Improve OS X UA quirk
Summary: [GTK] Improve OS X UA quirk
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: WebKit Nightly Build
Hardware: PC Linux
: P2 Normal
Assignee: Michael Catanzaro
URL:
Keywords:
Depends on:
Blocks: 142074 162610
  Show dependency treegraph
 
Reported: 2016-09-27 08:27 PDT by Michael Catanzaro
Modified: 2016-10-05 13:23 PDT (History)
3 users (show)

See Also:


Attachments
Patch (1.40 KB, patch)
2016-09-27 09:43 PDT, Michael Catanzaro
cgarcia: review+
commit-queue: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Catanzaro 2016-09-27 08:27:28 PDT
Add a fake OS X version number to the Macintosh quirk user agent, in order to more convincingly pretend to be OS X.
Comment 1 Michael Catanzaro 2016-09-27 09:43:57 PDT
Created attachment 289956 [details]
Patch
Comment 2 Carlos Garcia Campos 2016-09-28 03:40:35 PDT
Comment on attachment 289956 [details]
Patch

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

> Source/WebCore/platform/gtk/UserAgentGtk.cpp:134
> -        uaString.appendLiteral(" Mac OS X");
> +        uaString.appendLiteral(" Mac OS X 10_12");

is there any website broken because of this?
Comment 3 Michael Catanzaro 2016-09-28 05:38:06 PDT
(In reply to comment #2)
> is there any website broken because of this?

Not that I know of. Consider that this is a quirk that was previously only used at yahoo.com; I am just improving the quirk.
Comment 4 Carlos Garcia Campos 2016-09-28 06:25:00 PDT
Comment on attachment 289956 [details]
Patch

Ok, update the unit tests.
Comment 5 Michael Catanzaro 2016-09-28 07:27:44 PDT
(In reply to comment #4)
> Comment on attachment 289956 [details]
> Patch
> 
> Ok, update the unit tests.

I don't want to, because (a) updating the test would not accomplish much, as it would be difficult to unintentionally remove the hardcoded version, and (b) I want to change the version string here without having to modify the test. I will update the unit tests for the other two patches, though.
Comment 6 WebKit Commit Bot 2016-10-04 11:37:50 PDT
Comment on attachment 289956 [details]
Patch

Rejecting attachment 289956 [details] from commit-queue.

Failed to run "['/Volumes/Data/EWS/WebKit/Tools/Scripts/webkit-patch', '--status-host=webkit-queues.webkit.org', '--bot-id=webkit-cq-03', 'apply-attachment', '--no-update', '--non-interactive', 289956, '--port=mac']" exit_code: 2 cwd: /Volumes/Data/EWS/WebKit

Last 500 characters of output:
" exit_code: 1 cwd: /Volumes/Data/EWS/WebKit

Parsed 2 diffs from patch file(s).
patching file Source/WebCore/ChangeLog
Hunk #1 succeeded at 1 with fuzz 3.
patching file Source/WebCore/platform/gtk/UserAgentGtk.cpp
Hunk #1 FAILED at 131.
1 out of 1 hunk FAILED -- saving rejects to file Source/WebCore/platform/gtk/UserAgentGtk.cpp.rej

Failed to run "[u'/Volumes/Data/EWS/WebKit/Tools/Scripts/svn-apply', '--force', '--reviewer', u'Carlos Garcia Campos']" exit_code: 1 cwd: /Volumes/Data/EWS/WebKit

Full output: http://webkit-queues.webkit.org/results/2218936
Comment 7 Michael Catanzaro 2016-10-05 13:23:57 PDT
Committed r206826: <http://trac.webkit.org/changeset/206826>