From 4b368564091a0023e1981bd8346716db2474b068 Mon Sep 17 00:00:00 2001 From: jan iversen Date: Sat, 23 Jan 2016 18:38:24 +0100 Subject: cid#1326176, 1326270, 1326271, 1326272, 1326273, 1326274, 1326275 null pointer used to dereference, add "if" Change-Id: I37173f252a3b3da44976581ccefd0ed54aa8aa0d Reviewed-on: https://gerrit.libreoffice.org/21735 Tested-by: Jenkins Reviewed-by: jan iversen --- .../java/org/openoffice/xmerge/util/registry/ConverterInfo.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'xmerge') diff --git a/xmerge/source/xmerge/java/org/openoffice/xmerge/util/registry/ConverterInfo.java b/xmerge/source/xmerge/java/org/openoffice/xmerge/util/registry/ConverterInfo.java index b549743fe308..de377ec43f37 100644 --- a/xmerge/source/xmerge/java/org/openoffice/xmerge/util/registry/ConverterInfo.java +++ b/xmerge/source/xmerge/java/org/openoffice/xmerge/util/registry/ConverterInfo.java @@ -153,6 +153,10 @@ public class ConverterInfo { String version, String vendor, String impl) throws RegistryException { + if (officeMime == null || displayName == null || description == null || + version == null || vendor == null || impl == null) + throw new IllegalArgumentException("arguments unexpected null"); + if (!isValidOfficeType(officeMime.trim())) { RegistryException re = new RegistryException( "Invalid office type"); @@ -387,4 +391,4 @@ public class ConverterInfo { public String getXsltDeserial() { return piXsltDeserial; } -} \ No newline at end of file +} -- cgit