From 670a83eed2c9dd4b39654f99c18ed3dddb92644c Mon Sep 17 00:00:00 2001 From: "sspitzer%netscape.com" Date: Fri, 6 Aug 1999 07:42:27 +0000 Subject: [PATCH] use try and catch --- mailnews/base/resources/content/shareglue.js | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/mailnews/base/resources/content/shareglue.js b/mailnews/base/resources/content/shareglue.js index ce44e1c39078..8e87903ef507 100644 --- a/mailnews/base/resources/content/shareglue.js +++ b/mailnews/base/resources/content/shareglue.js @@ -76,9 +76,19 @@ function MessengerSetDefaultCharacterSet(aCharset) function Print() { dump("Print()\n"); - messenger.DoPrint(); + try { + messenger.DoPrint(); + } + catch (ex) { + dump("failed to print\n"); + } } function PrintPreview() { dump("PrintPreview()\n"); - messenger.DoPrintPreview(); + try { + messenger.DoPrintPreview(); + } + catch (ex) { + dump("failed to print preview\n"); + } }