cvs: pecl /hash hash.c

From: Date: Fri, 24 Aug 2007 21:27:39 +0000
Subject: cvs: pecl /hash hash.c
Groups: php.pecl.cvs 
Request: Send a blank email to pecl-cvs+get-8471@lists.php.net to get a copy of this message
pollita Fri Aug 24 21:27:39 2007 UTC Modified files: /pecl/hash hash.c Log: Fix hash_init() for PHP < 6 http://cvs.php.net/viewvc.cgi/pecl/hash/hash.c?r1=1.36&r2=1.37&diff_format=u Index: pecl/hash/hash.c diff -u pecl/hash/hash.c:1.36 pecl/hash/hash.c:1.37 --- pecl/hash/hash.c:1.36 Wed May 30 07:10:25 2007 +++ pecl/hash/hash.c Fri Aug 24 21:27:38 2007 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: hash.c,v 1.36 2007/05/30 07:10:25 mike Exp $ */ +/* $Id: hash.c,v 1.37 2007/08/24 21:27:38 pollita Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -341,13 +341,18 @@ { char *algo, *key = NULL; int algo_len, key_len = 0, argc = ZEND_NUM_ARGS(); - zend_uchar key_type; long options = 0; void *context; const php_hash_ops *ops; php_hash_data *hash; +#if PHP_MAJOR_VERSION >= 6 + zend_uchar key_type; + if (zend_parse_parameters(argc TSRMLS_CC, "s|lt", &algo, &algo_len, &options, &key, &key_len, &key_type) == FAILURE) { +#else + if (zend_parse_parameters(argc TSRMLS_CC, "s|ls", &algo, &algo_len, &options, &key, &key_len) == FAILURE) { +#endif return; }

« previous php.pecl.cvs (#8471) next »