diff --git a/ext/kernel/string.c b/ext/kernel/string.c index d4456af1a40..d9d70ec23cc 100644 --- a/ext/kernel/string.c +++ b/ext/kernel/string.c @@ -389,6 +389,9 @@ int phalcon_memnstr_str(const zval *haystack, char *needle, unsigned int needle_ */ void phalcon_fast_strpos(zval *return_value, const zval *haystack, const zval *needle) { +#if PHP_VERSION_ID >= 50600 + const +#endif char *found = NULL; if (unlikely(Z_TYPE_P(haystack) != IS_STRING || Z_TYPE_P(needle) != IS_STRING)) { @@ -418,6 +421,9 @@ void phalcon_fast_strpos(zval *return_value, const zval *haystack, const zval *n */ void phalcon_fast_strpos_str(zval *return_value, const zval *haystack, char *needle, unsigned int needle_length) { +#if PHP_VERSION_ID >= 50600 + const +#endif char *found = NULL; if (unlikely(Z_TYPE_P(haystack) != IS_STRING)) { @@ -441,6 +447,9 @@ void phalcon_fast_strpos_str(zval *return_value, const zval *haystack, char *nee */ void phalcon_fast_stripos_str(zval *return_value, zval *haystack, char *needle, unsigned int needle_length) { +#if PHP_VERSION_ID >= 50600 + const +#endif char *found = NULL; char *needle_dup, *haystack_dup;