From eb764fadccf690ac05dd1b9dac9e90b3bcf7827f Mon Sep 17 00:00:00 2001 From: Brett Meyer Date: Thu, 9 Jan 2014 14:41:07 -0500 Subject: [PATCH] HHH-8821 corrected failing test --- .../jpa/boot/archive/spi/AbstractArchiveDescriptor.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hibernate-entitymanager/src/main/java/org/hibernate/jpa/boot/archive/spi/AbstractArchiveDescriptor.java b/hibernate-entitymanager/src/main/java/org/hibernate/jpa/boot/archive/spi/AbstractArchiveDescriptor.java index 5694e206a0..1870ebd05a 100644 --- a/hibernate-entitymanager/src/main/java/org/hibernate/jpa/boot/archive/spi/AbstractArchiveDescriptor.java +++ b/hibernate-entitymanager/src/main/java/org/hibernate/jpa/boot/archive/spi/AbstractArchiveDescriptor.java @@ -74,7 +74,7 @@ public abstract class AbstractArchiveDescriptor implements ArchiveDescriptor { protected String extractRelativeName(ZipEntry zipEntry) { final String entryName = extractName( zipEntry ); - return entryBasePrefix == null ? entryName : entryName.substring( entryBasePrefix.length() ); + return entryBasePrefix != null && entryName.contains( entryBasePrefix ) ? entryName.substring( entryBasePrefix.length() ) : entryName; } protected String extractName(ZipEntry zipEntry) {