sas             Wed Nov 20 12:15:01 2002 EDT

  Modified files:              
    /php4/ext/session   session.c 
  Log:
  Add an error message to the ini handlers
  
  
Index: php4/ext/session/session.c
diff -u php4/ext/session/session.c:1.337 php4/ext/session/session.c:1.338
--- php4/ext/session/session.c:1.337    Wed Nov 20 11:06:29 2002
+++ php4/ext/session/session.c  Wed Nov 20 12:15:00 2002
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: session.c,v 1.337 2002/11/20 16:06:29 sas Exp $ */
+/* $Id: session.c,v 1.338 2002/11/20 17:15:00 sas Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -85,8 +85,10 @@
 
 static PHP_INI_MH(OnUpdateSaveHandler)
 {
-       if (PS(session_status) == php_session_active)
-               return;
+       if (PS(session_status) == php_session_active) {
+               php_error(E_WARNING, "A session is active. You cannot change the 
+session module's ini settings at this time.");
+               return FAILURE;
+       }
        PS(mod) = _php_find_ps_module(new_value TSRMLS_CC);
 /*
  * Following lines are commented out to prevent bogus error message at
@@ -104,8 +106,10 @@
 
 static PHP_INI_MH(OnUpdateSerializer)
 {
-       if (PS(session_status) == php_session_active)
-               return;
+       if (PS(session_status) == php_session_active) {
+               php_error(E_WARNING, "A session is active. You cannot change the 
+session module's ini settings at this time.");
+               return FAILURE;
+       }
        PS(serializer) = _php_find_ps_serializer(new_value TSRMLS_CC);
 /*
  * Following lines are commented out to prevent bogus error message at



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to