[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [Git][tpo/applications/mullvad-browser][mullvad-browser-140.7.0esr-15.0-1] Bug 1996718 - Check whether BrowserChild has not yet been destroyed in each...



Title: GitLab

ma1 pushed to branch mullvad-browser-140.7.0esr-15.0-1 at The Tor Project / Applications / Mullvad Browser

Commits:

  • 86bb5b91
    by Hiroyuki Ikezoe at 2026-01-12T12:19:31+01:00
    Bug 1996718 - Check whether BrowserChild has not yet been destroyed in each function of ContentProcessController. r=botond
    
    Differential Revision: https://phabricator.services.mozilla.com/D270278
    

1 changed file:

Changes:

  • gfx/layers/apz/util/ContentProcessController.cpp
    ... ... @@ -32,7 +32,7 @@ void ContentProcessController::NotifyLayerTransforms(
    32 32
     
    
    33 33
     void ContentProcessController::RequestContentRepaint(
    
    34 34
         const RepaintRequest& aRequest) {
    
    35
    -  if (mBrowser) {
    
    35
    +  if (mBrowser && !mBrowser->IsDestroyed()) {
    
    36 36
         mBrowser->UpdateFrame(aRequest);
    
    37 37
       }
    
    38 38
     }
    
    ... ... @@ -56,7 +56,7 @@ void ContentProcessController::NotifyPinchGesture(
    56 56
     void ContentProcessController::NotifyAPZStateChange(
    
    57 57
         const ScrollableLayerGuid& aGuid, APZStateChange aChange, int aArg,
    
    58 58
         Maybe<uint64_t> aInputBlockId) {
    
    59
    -  if (mBrowser) {
    
    59
    +  if (mBrowser && !mBrowser->IsDestroyed()) {
    
    60 60
         mBrowser->NotifyAPZStateChange(aGuid.mScrollId, aChange, aArg,
    
    61 61
                                        aInputBlockId);
    
    62 62
       }
    
    ... ... @@ -64,13 +64,13 @@ void ContentProcessController::NotifyAPZStateChange(
    64 64
     
    
    65 65
     void ContentProcessController::NotifyMozMouseScrollEvent(
    
    66 66
         const ScrollableLayerGuid::ViewID& aScrollId, const nsString& aEvent) {
    
    67
    -  if (mBrowser) {
    
    67
    +  if (mBrowser && !mBrowser->IsDestroyed()) {
    
    68 68
         APZCCallbackHelper::NotifyMozMouseScrollEvent(aScrollId, aEvent);
    
    69 69
       }
    
    70 70
     }
    
    71 71
     
    
    72 72
     void ContentProcessController::NotifyFlushComplete() {
    
    73
    -  if (mBrowser) {
    
    73
    +  if (mBrowser && !mBrowser->IsDestroyed()) {
    
    74 74
         RefPtr<PresShell> presShell = mBrowser->GetTopLevelPresShell();
    
    75 75
         APZCCallbackHelper::NotifyFlushComplete(presShell);
    
    76 76
       }
    
    ... ... @@ -113,7 +113,7 @@ void ContentProcessController::DispatchToRepaintThread(
    113 113
     }
    
    114 114
     
    
    115 115
     PresShell* ContentProcessController::GetTopLevelPresShell() const {
    
    116
    -  if (!mBrowser) {
    
    116
    +  if (!mBrowser || mBrowser->IsDestroyed()) {
    
    117 117
         return nullptr;
    
    118 118
       }
    
    119 119
       return mBrowser->GetTopLevelPresShell();
    

  • _______________________________________________
    tor-commits mailing list -- tor-commits@xxxxxxxxxxxxxxxxxxxx
    To unsubscribe send an email to tor-commits-leave@xxxxxxxxxxxxxxxxxxxx