From 507017df2bfa3ba354faf58dac12d566efe49b8b Mon Sep 17 00:00:00 2001 From: Nick Burch Date: Tue, 3 Jan 2006 11:59:43 +0000 Subject: [PATCH] Add (and throw) an exception if the powerpoint file is corrupt in a way that some seem to be (first record is of type 0000, and length is 0xFFFF) git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@365617 13f79535-47bb-0310-9956-ffa450edef68 --- .../CorruptPowerPointFileException.java | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 src/scratchpad/src/org/apache/poi/hslf/exceptions/CorruptPowerPointFileException.java diff --git a/src/scratchpad/src/org/apache/poi/hslf/exceptions/CorruptPowerPointFileException.java b/src/scratchpad/src/org/apache/poi/hslf/exceptions/CorruptPowerPointFileException.java new file mode 100644 index 0000000000..98f1e2c5b4 --- /dev/null +++ b/src/scratchpad/src/org/apache/poi/hslf/exceptions/CorruptPowerPointFileException.java @@ -0,0 +1,34 @@ + +/* ==================================================================== + Copyright 2002-2004 Apache Software Foundation + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +==================================================================== */ + + + +package org.apache.poi.hslf.exceptions; + +/** + * This exception is thrown when we try to open a PowerPoint file, and + * something is fundamentally broken about it. + * + * @author Nick Burch + */ + +public class CorruptPowerPointFileException extends IllegalStateException +{ + public CorruptPowerPointFileException(String s) { + super(s); + } +} -- 2.39.5