summaryrefslogtreecommitdiff
path: root/ext/session/mod_user_class.c
diff options
context:
space:
mode:
authorLeigh <leight@gmail.com>2012-06-26 14:57:10 +0100
committerArpad Ray <arraypad@gmail.com>2013-06-27 13:06:22 +0100
commitb794cce4fd4a6158002f3e8a814a30891cefbcde (patch)
tree5fdf8f2a899135ec329878446d2ad6918d9fa3ab /ext/session/mod_user_class.c
parent074c26a68b9484cd51734a70bb91b8afb585c212 (diff)
downloadphp-git-b794cce4fd4a6158002f3e8a814a30891cefbcde.tar.gz
Tests, fixes and optimisations
* Amended existing tests to cater for new functionality. * Implemented fixes and optimisations recommended by NikiC * Added create_sid to the registered interface. This was breaking tests. It also now breaks BC for people implementing the interface directly instead of extending the class.
Diffstat (limited to 'ext/session/mod_user_class.c')
-rw-r--r--ext/session/mod_user_class.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/session/mod_user_class.c b/ext/session/mod_user_class.c
index 340c2ca97a..ea53af9ebe 100644
--- a/ext/session/mod_user_class.c
+++ b/ext/session/mod_user_class.c
@@ -148,12 +148,12 @@ PHP_METHOD(SessionHandler, create_sid)
{
char *id;
- zend_parse_parameters_none();
+ if (zend_parse_parameters_none() == FAILURE) {
+ return;
+ }
id = PS(default_mod)->s_create_sid(&PS(mod_data), NULL TSRMLS_CC);
- RETVAL_STRING(id, 1);
- efree(id);
- return;
+ RETURN_STRING(id, 0);
}
/* }}} */