Couldn't it be that the server is killed because you call System.exit(1) in
the catch statement?

I believe that is intended for stand-alone applications and should never be
found in a servlet or jsp.

                -----Original Message-----
                From:   Alan Lun [mailto:[EMAIL PROTECTED]]
                Sent:   Tuesday, June 06, 2000 12:16 PM
                To:     [EMAIL PROTECTED]
                Subject:        tomcat server dies easy?

                When a servlet tries to read the file that doesn't exist,
the tomcat
                server is killed. I used a code from

"http://triton.towson.edu/~schmitt/server/servlet/guestbook6.java"

                try {
                     BufferedReader in = new BufferedReader(new
InputStreamReader(
                     new
FileInputStream("/usr/faculty/schmitt/.mysql-init")));
                    } catch (Exception e) {
                       out.println("guestbook6: cannot read .mysql-init");
                       System.exit(1);
                    }

                Any ideas?

                Thanks

                Alan

                [EMAIL PROTECTED]


===========================================================================
                To unsubscribe: mailto [EMAIL PROTECTED] with body:
"signoff JSP-INTEREST".
                Some relevant FAQs on JSP/Servlets can be found at:

                 http://java.sun.com/products/jsp/faq.html
                 http://www.esperanto.org.nz/jsp/jspfaq.html
                 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
                 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to