You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Alexey Volovoy <av...@yahoo.com> on 2001/01/15 20:29:29 UTC

Tomcat 4 and JSPC

Hello all,my name Alexey Volovoy and i'm java/xml
developer , recently i start working with JSP.
I was trying to use JSP command line compiler in
tomcat 4.0. Got the following error

2001-01-15 11:01:49 - ERROR-the file '\snoop.jsp'
generated the following genera
l exception: java.util.EmptyStackException

I'm not sure is it already fixed or not  but i tried
to debug it and it comes down to  this method

 private String resolveFileName(String inFileName) {
        boolean isAbsolute =
inFileName.startsWith("/");
 String fileName = 
     isAbsolute ?
     inFileName : (String)baseDirStack.peek() +
inFileName;
 String baseDir = 
     inFileName.substring(0,
inFileName.lastIndexOf("/") + 1);
 baseDirStack.push(baseDir);
 return fileName;
    }

in this class                     
public class ParserController { }

Initally stack is empty. I didn't spend much time to
figure out what is the problem , but i think
It should be either checked for be empty or something
like this should go first during initialization
String baseDir =     inFileName.substring(0,
inFileName.lastIndexOf("/") + 1);
baseDirStack.push(baseDir);

Best regards Alexey.
P.S. I'm apologize if this mail list wrong place for
it .


 

__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 
http://personal.mail.yahoo.com/