diff --git a/mozilla/webshell/tests/viewer/unix/gtk/nsGtkMain.cpp b/mozilla/webshell/tests/viewer/unix/gtk/nsGtkMain.cpp index 8490e0b3aa4..cfbbaebd973 100644 --- a/mozilla/webshell/tests/viewer/unix/gtk/nsGtkMain.cpp +++ b/mozilla/webshell/tests/viewer/unix/gtk/nsGtkMain.cpp @@ -46,7 +46,9 @@ int nsNativeViewerApp::Run() { OpenWindow(); + NS_ADDREF(mAppShell); mAppShell->Run(); + NS_IF_RELEASE(mAppShell); return 0; }