From d2925999eddb8dbf76427bc543273bb30cc4c91d Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 13 Jan 2009 13:30:04 +0000 Subject: [PATCH] - fix build --- ext/enchant/enchant.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/ext/enchant/enchant.c b/ext/enchant/enchant.c index f47a2b34e3..1cf68ad575 100755 --- a/ext/enchant/enchant.c +++ b/ext/enchant/enchant.c @@ -22,6 +22,8 @@ #ifdef HAVE_CONFIG_H #include "config.h" #endif +#include +#include #include #include "php.h" #include "php_ini.h" @@ -83,7 +85,7 @@ function_entry enchant_functions[] = { PHP_FE(enchant_dict_store_replacement, NULL) PHP_FE(enchant_dict_get_error, NULL) PHP_FE(enchant_dict_describe, NULL) - PHP_FE(enchant_dict_quick_check, third_arg_force_ref) + PHP_FE(enchant_dict_quick_check, NULL) {NULL, NULL, NULL} /* Must be the last line in enchant_functions[] */ }; @@ -569,13 +571,13 @@ PHP_FUNCTION(enchant_dict_quick_check) PHP_ENCHANT_GET_DICT; if (enchant_dict_check(pdict->pdict, word, wordlen) > 0) { + int n_sugg; + char **suggs; + if (!sugg && ZEND_NUM_ARGS() == 2) { RETURN_FALSE; } - int n_sugg; - char **suggs; - array_init(sugg); suggs = enchant_dict_suggest(pdict->pdict, word, wordlen, (size_t *) &n_sugg); -- 2.50.1