Bug 64015

Summary: IconDatabase::synchronousIconForPageURL() has inconsistent API when no custom icon is available
Product: WebKit Reporter: John Sullivan <sullivan>
Component: WebKit Misc.Assignee: John Sullivan <sullivan>
Status: RESOLVED FIXED    
Severity: Normal CC: webkit.review.bot
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Patch to return 0 in all cases for which there is no custom icon
sullivan: review-
Patch to return 0 in all cases where there is no custom icon (now with ChangeLog)
sullivan: review-
Patch to always return 0 if there's no custom icon (now with correctly-styled ChangeLog!) adachan: review+

Description John Sullivan 2011-07-06 12:48:44 PDT
IconDatabase::synchronousIconForPageURL() returns 0 for some URLs that don't have custom icons (http/https ones), but instead returns the default icon (at a particular image size) for other URLs that don't have custom icons (anything other than http/https). This inconsistency makes it impossible to use the return value to know whether the page has a custom icon, or to use any client-specific default icon.

In Radar as <rdar://problem/9706277>.
Comment 1 John Sullivan 2011-07-06 12:54:52 PDT
Created attachment 99862 [details]
Patch to return 0 in all cases for which there is no custom icon
Comment 2 John Sullivan 2011-07-06 12:55:12 PDT
Oops, forgot the ChangeLog. Will resubmit.
Comment 3 John Sullivan 2011-07-06 12:58:22 PDT
Created attachment 99864 [details]
Patch to return 0 in all cases where there is no custom icon (now with ChangeLog)
Comment 4 John Sullivan 2011-07-06 12:59:31 PDT
Oops, neglected to add bugzilla URL to ChangeLog. Third time's a charm!
Comment 5 WebKit Review Bot 2011-07-06 13:00:02 PDT
Attachment 99864 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/ChangeLog', u'Source/WebCor..." exit_code: 1

Source/WebCore/ChangeLog:1:  ChangeLog entry has no bug number  [changelog/bugnumber] [5]
Total errors found: 1 in 2 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 6 John Sullivan 2011-07-06 13:00:10 PDT
Created attachment 99866 [details]
Patch to always return 0 if there's no custom icon (now with correctly-styled ChangeLog!)
Comment 7 John Sullivan 2011-07-06 13:29:17 PDT
Fixed in http://trac.webkit.org/changeset/90486