com php-src: Fix compile warnings about comparison of unsigned expression always being true: ext/oci8/oci8_interface.c ext/oci 8/oci8_lob.c
| From: | Christopher Jones | Date: | Fri, 06 Nov 2015 15:14:18 +0000 |
| Subject: | com php-src: Fix compile warnings about comparison of unsigned expression always being true: ext/oci8/oci8_interface.c ext/oci 8/oci8_lob.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-89614@lists.php.net to get a copy of this message | ||
Commit: a57b2053832fc0136d6b894148d0d20c0d9d90df
Author: Christopher Jones <christopher.jones@oracle.com> Sat, 7 Nov 2015 02:14:18
+1100
Parents: f88a9a964368ad21e78cf96197952aa3e03d4604
Branches: PHP-5..6
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=a57b2053832fc0136d6b894148d0d20c0d9d90df
Log:
Fix compile warnings about comparison of unsigned expression always being true
Changed paths:
M ext/oci8/oci8_interface.c
M ext/oci8/oci8_lob.c
Diff:
diff --git a/ext/oci8/oci8_interface.c b/ext/oci8/oci8_interface.c
index bb72122..817b8db 100644
--- a/ext/oci8/oci8_interface.c
+++ b/ext/oci8/oci8_interface.c
@@ -373,7 +373,7 @@ PHP_FUNCTION(oci_lob_eof)
PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
- if (!php_oci_lob_get_length(descriptor, &lob_length TSRMLS_CC) && lob_length >= 0)
{
+ if (!php_oci_lob_get_length(descriptor, &lob_length TSRMLS_CC)) {
if (lob_length == descriptor->lob_current_position) {
RETURN_TRUE;
}
diff --git a/ext/oci8/oci8_lob.c b/ext/oci8/oci8_lob.c
index ca08373..079e0a6 100644
--- a/ext/oci8/oci8_lob.c
+++ b/ext/oci8/oci8_lob.c
@@ -417,10 +417,6 @@ int php_oci_lob_write (php_oci_descriptor *descriptor, ub4 offset, char *data,
i
return 0;
}
- if (offset < 0) {
- offset = 0;
- }
-
if (offset > descriptor->lob_current_position) {
offset = descriptor->lob_current_position;
}