diff options
author | Ilia Alshanetsky <iliaa@php.net> | 2002-12-29 18:50:55 +0000 |
---|---|---|
committer | Ilia Alshanetsky <iliaa@php.net> | 2002-12-29 18:50:55 +0000 |
commit | c731daeda73220779e85dadbb7df8be91cf20d38 (patch) | |
tree | d66dbda9e48a5251cab3ab36ec80bebd831a2ecf | |
parent | ac1133d364c1ea9cb397b92b24f51394e91d350a (diff) | |
download | php-git-c731daeda73220779e85dadbb7df8be91cf20d38.tar.gz |
Fixed bug #21268 (session_decode() returned FALSE on success).
-rw-r--r-- | ext/session/session.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/ext/session/session.c b/ext/session/session.c index 8b6be415ab..f8c2806638 100644 --- a/ext/session/session.c +++ b/ext/session/session.c @@ -1433,15 +1433,19 @@ PHP_FUNCTION(session_decode) { zval **str; - if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, &str) == FAILURE) + if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, &str) == FAILURE) { WRONG_PARAM_COUNT; + } - if (PS(session_status) == php_session_none) + if (PS(session_status) == php_session_none) { RETURN_FALSE; + } convert_to_string_ex(str); php_session_decode(Z_STRVAL_PP(str), Z_STRLEN_PP(str) TSRMLS_CC); + + RETURN_TRUE; } /* }}} */ |