Title: [165445] releases/WebKitGTK/webkit-2.4/Source/WebKit2
Revision
165445
Author
[email protected]
Date
2014-03-11 04:10:11 -0700 (Tue, 11 Mar 2014)

Log Message

Merge r165371 - [GTK] The web process can finish while a print operation is still ongoing
https://bugs.webkit.org/show_bug.cgi?id=129871

Reviewed by Martin Robinson.

This can happen when the last page is closed while the print job
is sending data to the printer.

* WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp: Disable web
process termination when the print job is sending data to the
printer and enable it again when job finishes.

Modified Paths

Diff

Modified: releases/WebKitGTK/webkit-2.4/Source/WebKit2/ChangeLog (165444 => 165445)


--- releases/WebKitGTK/webkit-2.4/Source/WebKit2/ChangeLog	2014-03-11 11:07:15 UTC (rev 165444)
+++ releases/WebKitGTK/webkit-2.4/Source/WebKit2/ChangeLog	2014-03-11 11:10:11 UTC (rev 165445)
@@ -1,3 +1,17 @@
+2014-03-10  Carlos Garcia Campos  <[email protected]>
+
+        [GTK] The web process can finish while a print operation is still ongoing
+        https://bugs.webkit.org/show_bug.cgi?id=129871
+
+        Reviewed by Martin Robinson.
+
+        This can happen when the last page is closed while the print job
+        is sending data to the printer.
+
+        * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp: Disable web
+        process termination when the print job is sending data to the
+        printer and enable it again when job finishes.
+
 2014-03-07  Carlos Garcia Campos  <[email protected]>
 
         [GTK] Use final and override in WebPrintOperationGtk

Modified: releases/WebKitGTK/webkit-2.4/Source/WebKit2/WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp (165444 => 165445)


--- releases/WebKitGTK/webkit-2.4/Source/WebKit2/WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp	2014-03-11 11:07:15 UTC (rev 165444)
+++ releases/WebKitGTK/webkit-2.4/Source/WebKit2/WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp	2014-03-11 11:10:11 UTC (rev 165445)
@@ -29,6 +29,7 @@
 #include "WebCoreArgumentCoders.h"
 #include "WebPage.h"
 #include "WebPageProxyMessages.h"
+#include "WebProcess.h"
 #include <WebCore/DocumentLoader.h>
 #include <WebCore/ErrorsGtk.h>
 #include <WebCore/Frame.h>
@@ -147,10 +148,14 @@
     static void printJobFinished(WebPrintOperationGtkUnix* printOperation)
     {
         printOperation->deref();
+        WebProcess::shared().enableTermination();
     }
 
     void endPrint() override
     {
+        // Disable web process termination until the print job finishes.
+        WebProcess::shared().disableTermination();
+
         cairo_surface_finish(gtk_print_job_get_surface(m_printJob.get(), 0));
         // Make sure the operation is alive until the job is sent.
         ref();
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to