If a printer is not selected or there is some other driver failure, certain
printer drivers will crash Classilla because they throw an alert box and
don't put up their regular print dialogue, which Classilla is expecting. I
encountered this with the Brother print driver. Fix to printingui and
embedcomponents in nsPrintingPromptService::ShowPrintDialog():
// get pointer to invisible job dialog box
gPrtJobDialog = ::PrJobInit(printRecH);
if (::PrError() != noErr || !gPrtJobDialog) { // || !gPrtJobDialog added
Classilla issue 121
::DisposeHandle((Handle)printRecH);
::PrClose();
return NS_ERROR_FAILURE;
}
Now if an error occurs, then Classilla simply remarks that printing failed
for some reason, and the browser does not crash.
Original issue reported on code.google.com by classi...@floodgap.com on 22 May 2010 at 1:59
Original issue reported on code.google.com by
classi...@floodgap.com
on 22 May 2010 at 1:59