• Eric Orth's avatar
    Fix bad cast of malformed https rdata · b130811c
    Eric Orth authored
    Another case of the apparently poor job I did adding in the malformed
    vairant of HttpsRecordRdata.  ServiceFormHttpsRecordRdata::IsEqual() did
    not check if the input was malformed before casting to service form. Fix
    is to check before casting, and also to use the AsServiceForm() helper
    instead of a raw cast, as the helper has the CHECKs designed to make
    bugs like this obvious.
    
    Fixed: 1146873
    Change-Id: I5222a09c9c032bc163ca1beebf4bf1e0504ccad6
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2526931
    Commit-Queue: Eric Orth <ericorth@chromium.org>
    Commit-Queue: Dan McArdle <dmcardle@chromium.org>
    Auto-Submit: Eric Orth <ericorth@chromium.org>
    Reviewed-by: default avatarDan McArdle <dmcardle@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#825500}
    b130811c
https_record_rdata.cc 14.1 KB