redo the fix with cast to size_t
authorAnatol Belski <ab@php.net>
Tue, 16 Sep 2014 11:22:00 +0000 (13:22 +0200)
committerAnatol Belski <ab@php.net>
Tue, 16 Sep 2014 19:17:22 +0000 (21:17 +0200)
Zend/zend_vm_def.h
Zend/zend_vm_execute.h

index a3ae246579f112fea8998a951d52a25017f4b491..c591b9b4cca0b5482d613a225e046e45c257fc2d 100644 (file)
@@ -5067,7 +5067,7 @@ ZEND_VM_C_LABEL(num_index_prop):
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
index 1a2defd5849896dff70820b2dcbc0bd427efc83b..fb2456070ef55940c5d9475cc0c689f2c094ebc3 100644 (file)
@@ -4686,7 +4686,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -5747,7 +5747,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -7080,7 +7080,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -8887,7 +8887,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -11280,7 +11280,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -12265,7 +12265,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -13555,7 +13555,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -15124,7 +15124,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -19219,7 +19219,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -21201,7 +21201,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -23552,7 +23552,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -26776,7 +26776,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -28242,7 +28242,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -29527,7 +29527,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -30814,7 +30814,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -32610,7 +32610,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -36193,7 +36193,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -38086,7 +38086,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -40317,7 +40317,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;
@@ -43285,7 +43285,7 @@ num_index_prop:
                        }
                }
                if (Z_TYPE_P(offset) == IS_LONG) {
-                       if (offset->value.lval >= 0 && offset->value.lval < (zend_long)Z_STRLEN_P(container)) {
+                       if (offset->value.lval >= 0 && (size_t)offset->value.lval < Z_STRLEN_P(container)) {
                                if ((opline->extended_value & ZEND_ISSET) ||
                                    Z_STRVAL_P(container)[offset->value.lval] != '0') {
                                        result = 1;