$NetBSD: patch-ab,v 1.4 2004/03/03 10:50:09 adam Exp $

--- xpdf/XPDFViewer.cc.orig	2004-01-22 01:26:45.000000000 +0000
+++ xpdf/XPDFViewer.cc
@@ -181,9 +181,12 @@ XPDFViewer::XPDFViewer(XPDFApp *appA, GS
 
 XPDFViewer::~XPDFViewer() {
   delete core;
-  XmFontListFree(aboutBigFont);
-  XmFontListFree(aboutVersionFont);
-  XmFontListFree(aboutFixedFont);
+  if(aboutBigFont)
+    XmFontListFree(aboutBigFont);
+  if(aboutVersionFont)
+    XmFontListFree(aboutVersionFont);
+  if(aboutFixedFont)
+    XmFontListFree(aboutFixedFont);
   closeWindow();
 #ifndef DISABLE_OUTLINE
   if (outlineLabels) {
