Re: [ZEND-ENGINE-CVS] cvs: ZendEngine2 / zend_execute_API.c
| From: | Andi Gutmans | Date: | Mon, 27 Sep 2004 16:40:49 +0000 |
| Subject: | Re: [ZEND-ENGINE-CVS] cvs: ZendEngine2 / zend_execute_API.c | ||
| References: | 1 | Groups: | php.zend-engine.cvs |
| Request: | Send a blank email to php-zend-engine-cvs+get-3041@lists.php.net to get a copy of this message | ||
str.len used to be able to be -1. I can't quite remember when but we used it to mark a special case. I am not sure if it's still required today.
I prefer not casting such places so that we remember to check back and see why the warning is happening. You are only suppressing a warning but not fixing anything.
Your previous commits were OK because they actually solved warnings without casting.
Andi
At 08:50 AM 9/27/2004 +0000, Marcus Boerger wrote:
helly Mon Sep 27 04:50:43 2004 EDTModified files:/ZendEngine2 zend_execute_API.cLog: - Fix warning # What's the reason _zvalue_value.str.len is int instead of uint/zend_uint? http://cvs.php.net/diff.php/ZendEngine2/zend_execute_API.c?r1=1.299&r2=1.300&ty=u Index: ZendEngine2/zend_execute_API.c diff -u ZendEngine2/zend_execute_API.c:1.299 ZendEngine2/zend_execute_API.c:1.300--- ZendEngine2/zend_execute_API.c:1.299 Thu Sep 23 17:43:32 2004 +++ ZendEngine2/zend_execute_API.c Mon Sep 27 04:50:41 2004@@ -17,7 +17,7 @@+----------------------------------------------------------------------+*/ -/* $Id: zend_execute_API.c,v 1.299 2004/09/23 21:43:32 andi Exp $ */ +/* $Id: zend_execute_API.c,v 1.300 2004/09/27 08:50:41 helly Exp $ */ #include <stdio.h> #include <signal.h> @@ -479,7 +479,7 @@continue; }- if (const_value.type == IS_STRING && const_value.value.str.len == str_index_len-1 && + if (const_value.type == IS_STRING && (uint)const_value.value.str.len == str_index_len-1 && !strncmp(const_value.value.str.val, str_index, str_index_len)) { /* constant value is the same as its name */ zval_dtor(&const_value);-- Zend Engine CVS Mailing List (http://cvs.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php