Index: trunk/extensions/FastStringSearch/fss.c |
— | — | @@ -9,6 +9,7 @@ |
10 | 10 | #endif |
11 | 11 | |
12 | 12 | #include "php.h" |
| 13 | +#include "Zend/zend.h" |
13 | 14 | #include "php_ini.h" |
14 | 15 | #include "ext/standard/info.h" |
15 | 16 | #include "php_fss.h" |
— | — | @@ -215,7 +216,7 @@ |
216 | 217 | if (zend_hash_get_current_key_ex(hash, &string_key, &string_key_len, &num_key, 0, |
217 | 218 | &hpos) == HASH_KEY_IS_LONG) |
218 | 219 | { |
219 | | - sprintf(buffer, "%u", num_key); |
| 220 | + sprintf(buffer, "%lu", num_key); |
220 | 221 | string_key = buffer; |
221 | 222 | string_key_len = strlen(buffer); |
222 | 223 | } else { |
— | — | @@ -240,7 +241,11 @@ |
241 | 242 | |
242 | 243 | /* Add the value to the replace array */ |
243 | 244 | convert_to_string_ex(value); |
| 245 | +#ifdef Z_ADDREF_P /* 5.3 */ |
| 246 | + Z_ADDREF_P(*value); |
| 247 | +#else |
244 | 248 | ZVAL_ADDREF(*value); |
| 249 | +#endif |
245 | 250 | res->replace[i] = *value; |
246 | 251 | } |
247 | 252 | kwsprep(res->set); |