• Lei Zhang's avatar
    Fix sequencing in PrintDialogGtk. · e7a8dba5
    Lei Zhang authored
    In https://crrev.com/751341, the DCHECK for which sequence
    PrintDialogGtk::PrintDocument() runs on accidentally got negated.
    As a result, it also posted a task for SendDocumentToPrinter() on the
    wrong sequence.
    
    Fix the DCHECK in PrintDocument() to match the comment right above it,
    and post the SendDocumentToPrinter() task to the right sequence. To do
    so, take advantage of the fact that PrintDialogGtk inherits from
    base::RefCountedDeleteOnSequence(), so it already knows what sequence it
    lives on. Thus it does not need a separate base::SequenceChecker.
    
    Bug: 1082740
    Change-Id: I632527fe7ae63c5ecb2bb954c50f3df62d398684
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2228113Reviewed-by: default avatarThomas Anderson <thomasanderson@chromium.org>
    Commit-Queue: Lei Zhang <thestig@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#774735}
    e7a8dba5
print_dialog_gtk.cc 17.9 KB