Check parameter count for yaz_wai PHPYAZ-22
authorAdam Dickmeiss <adam@indexdata.dk>
Thu, 17 Oct 2013 11:38:43 +0000 (13:38 +0200)
committerAdam Dickmeiss <adam@indexdata.dk>
Thu, 17 Oct 2013 11:38:43 +0000 (13:38 +0200)
php_yaz.c

index 1ba1217..0964cbd 100644 (file)
--- a/php_yaz.c
+++ b/php_yaz.c
@@ -594,6 +594,9 @@ PHP_FUNCTION(yaz_wait)
                if (event_bool && *event_bool)
                        event_mode = 1;
        }
+       else if (ZEND_NUM_ARGS() > 1) {
+               WRONG_PARAM_COUNT;
+       }
 #ifdef ZTS
        tsrm_mutex_lock(yaz_mutex);
 #endif