From 329643c9f409949cd977f8386b34c14fe316a184 Mon Sep 17 00:00:00 2001 From: Jeremias Maerki Date: Sat, 11 Jan 2003 21:17:40 +0000 Subject: [PATCH] Fixed a NullPointerException experienced by some DocBook users. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/fop-0_20_2-maintain@195845 13f79535-47bb-0310-9956-ffa450edef68 --- src/org/apache/fop/extensions/Label.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/org/apache/fop/extensions/Label.java b/src/org/apache/fop/extensions/Label.java index 791724e94..c21f84933 100644 --- a/src/org/apache/fop/extensions/Label.java +++ b/src/org/apache/fop/extensions/Label.java @@ -1,6 +1,6 @@ /* * $Id$ - * Copyright (C) 2001 The Apache Software Foundation. All rights reserved. + * Copyright (C) 2001-2003 The Apache Software Foundation. All rights reserved. * For details on use and redistribution please refer to the * LICENSE file included with these sources. */ @@ -41,7 +41,11 @@ public class Label extends ExtensionObj { } public String toString() { - return textBuffer.toString(); + if (textBuffer != null) { + return textBuffer.toString(); + } else { + return null; + } } public String getName() { -- 2.39.5