From 0a1b9548daabd8ed5b89b4e8dd8dfbd388d5d9c1 Mon Sep 17 00:00:00 2001 From: netconomy Date: Thu, 22 Nov 2007 08:28:53 +0000 Subject: fixed the "NullPtrEx Freie Texteingabe" bug git-svn-id: https://joinup.ec.europa.eu/svn/pdf-as/trunk@228 7b5415b0-85f9-ee4d-85bd-d5d0c3b42d1c --- src/main/java/at/gv/egiz/pdfas/web/helper/TempDirHelper.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/at/gv/egiz/pdfas/web/helper/TempDirHelper.java b/src/main/java/at/gv/egiz/pdfas/web/helper/TempDirHelper.java index c16b96f..3775776 100644 --- a/src/main/java/at/gv/egiz/pdfas/web/helper/TempDirHelper.java +++ b/src/main/java/at/gv/egiz/pdfas/web/helper/TempDirHelper.java @@ -272,6 +272,10 @@ public class TempDirHelper */ public static String extractFileNameSuffix (String file) { + if (file == null || file.trim().length() == 0) + { + return "nofilename"; + } File f = new File(file); return f.getName(); } -- cgit v1.2.3