-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: JarVisitor and folder names < 4 chars
PostPosted: Wed Nov 23, 2005 10:00 am 
Newbie

Joined: Thu Sep 01, 2005 8:43 am
Posts: 14
Hi,

I guess this is a known issue (also mentioned in http://forum.hibernate.org/viewtopic.php?t=946696), but still:
The code in org.hibernate.ejb.packaging.JarVisitor
Code:
if (fileName.endsWith( "ar" ) && fileName.charAt( fileName.length() - 4 ) == '.' )

works only if fileName is longer than 4 chars.
Is there a naming convention that does not allow the StringIndexOutOfBoundsException to happen?

cu,


Top
 Profile  
 
 Post subject:
PostPosted: Wed Nov 23, 2005 12:36 pm 
Expert
Expert

Joined: Sat Oct 25, 2003 8:49 am
Posts: 490
Location: Vrhnika, Slovenia
Aren't all files constructed similary:
<name>.<suffix>

Are you using only a single char suffix?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Nov 24, 2005 4:51 am 
Newbie

Joined: Thu Sep 01, 2005 8:43 am
Posts: 14
Nope -> I didn't pack my persistrence.xml in a .par archive -> I just put it in a folder called par/META-INF and put par in the class path. For sure not a solution for the real life, but as long as the folder has > 4 chars good enough for testing :) As I found out :)
cu,


Top
 Profile  
 
 Post subject:
PostPosted: Fri Nov 25, 2005 7:03 am 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
I fixed that in CVS, thanks

_________________
Emmanuel


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.