cvs: php4 /sapi/servlet servlet.java

From: Date: Tue, 27 Jun 2000 10:37:36 +0000
Subject: cvs: php4 /sapi/servlet servlet.java
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-504@lists.php.net to get a copy of this message
rubys Tue Jun 27 03:37:36 2000 EDT Modified files: /php4/sapi/servlet servlet.java Log: defer loading of the native code Index: php4/sapi/servlet/servlet.java diff -u php4/sapi/servlet/servlet.java:1.10 php4/sapi/servlet/servlet.java:1.11 --- php4/sapi/servlet/servlet.java:1.10 Tue Jun 13 18:41:11 2000 +++ php4/sapi/servlet/servlet.java Tue Jun 27 03:37:36 2000 @@ -42,7 +42,6 @@ /* native methods */ /******************************************************************/ - static { reflect.loadLibrary("servlet"); } public native void startup(); public native long define(String name); public native void send(String requestMethod, String queryString, @@ -124,7 +123,12 @@ public void init(ServletConfig config) throws ServletException { super.init(config); - if (0 == startup_count++) startup(); + + // first time in, initialize native code + if (0 == startup_count++) { + reflect.loadLibrary("servlet"); + startup(); + } // try to find the addHeader method (added in the servlet API 2.2) // otherwise settle for the setHeader method

« previous php.cvs (#504) next »