jani            Mon Nov  5 11:52:31 2007 UTC

  Modified files:              (Branch: PHP_5_3)
    /php-src/ext/standard       assert.c 
  Log:
  MFH: ws + cs + folding tags
  
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/assert.c?r1=1.60.2.3.2.6&r2=1.60.2.3.2.6.2.1&diff_format=u
Index: php-src/ext/standard/assert.c
diff -u php-src/ext/standard/assert.c:1.60.2.3.2.6 
php-src/ext/standard/assert.c:1.60.2.3.2.6.2.1
--- php-src/ext/standard/assert.c:1.60.2.3.2.6  Fri Feb 16 16:35:04 2007
+++ php-src/ext/standard/assert.c       Mon Nov  5 11:52:31 2007
@@ -14,15 +14,15 @@
    +----------------------------------------------------------------------+
    | Author: Thies C. Arntzen <[EMAIL PROTECTED]>                          |
    +----------------------------------------------------------------------+
- */
-
-/* $Id: assert.c,v 1.60.2.3.2.6 2007/02/16 16:35:04 dmitry Exp $ */
+*/
 
-/* {{{ includes/startup/misc */
+/* $Id: assert.c,v 1.60.2.3.2.6.2.1 2007/11/05 11:52:31 jani Exp $ */
 
+/* {{{ includes */
 #include "php.h"
 #include "php_assert.h"
 #include "php_ini.h"
+/* }}} */
 
 ZEND_BEGIN_MODULE_GLOBALS(assert)
        long active;
@@ -51,7 +51,7 @@
        ASSERT_QUIET_EVAL
 };
 
-static PHP_INI_MH(OnChangeCallback)
+static PHP_INI_MH(OnChangeCallback) /* {{{ */
 {
        if (EG(in_execution)) {
                if (ASSERTG(callback)) {
@@ -75,22 +75,24 @@
        }
        return SUCCESS;
 }
+/* }}} */
 
 PHP_INI_BEGIN()
-        STD_PHP_INI_ENTRY("assert.active",         "1",        PHP_INI_ALL,    
OnUpdateLong,           active,                         zend_assert_globals,    
        assert_globals)
-        STD_PHP_INI_ENTRY("assert.bail",           "0",        PHP_INI_ALL,    
OnUpdateLong,           bail,                           zend_assert_globals,    
        assert_globals)
+        STD_PHP_INI_ENTRY("assert.active",             "1",    PHP_INI_ALL,    
OnUpdateLong,           active,                         zend_assert_globals,    
        assert_globals)
+        STD_PHP_INI_ENTRY("assert.bail",               "0",    PHP_INI_ALL,    
OnUpdateLong,           bail,                           zend_assert_globals,    
        assert_globals)
         STD_PHP_INI_ENTRY("assert.warning",    "1",    PHP_INI_ALL,    
OnUpdateLong,           warning,                        zend_assert_globals,    
        assert_globals)
-        PHP_INI_ENTRY    ("assert.callback",   NULL,   PHP_INI_ALL,    
OnChangeCallback)
+        PHP_INI_ENTRY("assert.callback",               NULL,   PHP_INI_ALL,    
OnChangeCallback)
         STD_PHP_INI_ENTRY("assert.quiet_eval", "0",    PHP_INI_ALL,    
OnUpdateLong,           quiet_eval,                     zend_assert_globals,    
        assert_globals)
 PHP_INI_END()
 
-static void php_assert_init_globals(zend_assert_globals *assert_globals_p 
TSRMLS_DC)
+static void php_assert_init_globals(zend_assert_globals *assert_globals_p 
TSRMLS_DC) /* {{{ */
 {
        assert_globals_p->callback = NULL;
        assert_globals_p->cb = NULL;
 }
+/* }}} */
 
-PHP_MINIT_FUNCTION(assert)
+PHP_MINIT_FUNCTION(assert) /* {{{ */
 {
        ZEND_INIT_MODULE_GLOBALS(assert, php_assert_init_globals, NULL);
 
@@ -104,8 +106,9 @@
 
        return SUCCESS;
 }
+/* }}} */
 
-PHP_MSHUTDOWN_FUNCTION(assert)
+PHP_MSHUTDOWN_FUNCTION(assert) /* {{{ */
 {
        if (ASSERTG(cb)) {
                pefree(ASSERTG(cb), 1);
@@ -113,35 +116,34 @@
        }
        return SUCCESS;
 }
+/* }}} */
 
-PHP_RSHUTDOWN_FUNCTION(assert)
+PHP_RSHUTDOWN_FUNCTION(assert) /* {{{ */
 {
-       if (ASSERTG(callback)) { 
+       if (ASSERTG(callback)) {
                zval_ptr_dtor(&ASSERTG(callback));
                ASSERTG(callback) = NULL;
        }
 
        return SUCCESS;
 }
+/* }}} */
 
-PHP_MINFO_FUNCTION(assert)
+PHP_MINFO_FUNCTION(assert) /* {{{ */
 {
        DISPLAY_INI_ENTRIES();
 }
-
-/* }}} */
-/* {{{ internal functions */
 /* }}} */
+
 /* {{{ proto int assert(string|bool assertion)
    Checks if assertion is false */
-
 PHP_FUNCTION(assert)
 {
-       zval **assertion;       
+       zval **assertion;
        int val;
        char *myeval = NULL;
        char *compiled_string_description;
-       
+
        if (! ASSERTG(active)) {
                RETURN_TRUE;
        }
@@ -206,7 +208,7 @@
                ZVAL_STRING(args[0], SAFE_STRING(filename), 1);
                ZVAL_LONG (args[1], lineno);
                ZVAL_STRING(args[2], SAFE_STRING(myeval), 1);
-               
+
                MAKE_STD_ZVAL(retval);
                ZVAL_FALSE(retval);
 
@@ -231,17 +233,16 @@
                zend_bailout();
        }
 }
-
 /* }}} */
+
 /* {{{ proto mixed assert_options(int what [, mixed value])
    Set/get the various assert flags */
-
 PHP_FUNCTION(assert_options)
 {
        zval **what, **value;
        int oldint;
        int ac = ZEND_NUM_ARGS();
-       
+
        if (ac < 1 || ac > 2 || zend_get_parameters_ex(ac, &what, &value) == 
FAILURE) {
                WRONG_PARAM_COUNT;
        }
@@ -310,7 +311,6 @@
 
        RETURN_FALSE;
 }
-
 /* }}} */
 
 /*

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

Reply via email to