Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 3ad9e87e41ee56322c335a1dfbd0ccf794e57f7f
      
https://github.com/WebKit/WebKit/commit/3ad9e87e41ee56322c335a1dfbd0ccf794e57f7f
  Author: Charlie Wolfe <[email protected]>
  Date:   2026-06-24 (Wed, 24 Jun 2026)

  Changed paths:
    M Source/WebKit/Shared/Cocoa/CoreIPCNSURLCredential.mm
    M Tools/TestWebKitAPI/Tests/IPC/IPCSerialization.mm

  Log Message:
  -----------
  CoreIPCNSURLCredential attribute type guard is always true
https://bugs.webkit.org/show_bug.cgi?id=317444
rdar://180069344

Reviewed by Sihui Liu.

The guard meant to reject an attribute value that is none of NSString, NSNumber 
or NSDate was
written with ||. Since a value can be at most one of those classes, at least 
two of the negated
checks are always true, so the expression is always true. The body therefore 
fired on the very first
attribute regardless of its type, terminating the loop and dropping every 
credential attribute from
the IPC encoding. Use && so the guard rejects only values that are none of the 
three classes.

Test: Tools/TestWebKitAPI/Tests/IPC/IPCSerialization.mm
* Source/WebKit/Shared/Cocoa/CoreIPCNSURLCredential.mm:
(WebKit::CoreIPCNSURLCredential::CoreIPCNSURLCredential):
* Tools/TestWebKitAPI/Tests/IPC/IPCSerialization.mm:
(TEST(IPCSerialization, NSURLCredentialAttributes)):

Canonical link: https://commits.webkit.org/315792@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to