com php-src: Fixed bug #70991 (zend_file_cache.c:7 10: error: array type has incomplete elemen t type): NEWS ext/opcache/config.m4 ext/opcache
/zend_file_cache.c
| From: | Xinchen Hui | Date: | Tue, 01 Dec 2015 02:35:32 +0000 |
| Subject: | com php-src: Fixed bug #70991 (zend_file_cache.c:7 10: error: array type has incomplete elemen t type): NEWS ext/opcache/config.m4 ext/opcache /zend_file_cache.c |
||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-90068@lists.php.net to get a copy of this message | ||
Commit: ed4b887cf6e59c12428ebece5492201c63bfbb4f
Author: Xinchen Hui <laruence@gmail.com> Tue, 1 Dec 2015 10:35:32 +0800
Parents: 00e3b7614e5f6d845f1135d2e559638be525af24
Branches: PHP-7.0 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=ed4b887cf6e59c12428ebece5492201c63bfbb4f
Log:
Fixed bug #70991 (zend_file_cache.c:710: error: array type has incomplete element type)
Bugs:
https://bugs.php.net/70991
Changed paths:
M NEWS
M ext/opcache/config.m4
M ext/opcache/zend_file_cache.c
Diff:
diff --git a/NEWS b/NEWS
index bd59de3..42be771 100644
--- a/NEWS
+++ b/NEWS
@@ -36,6 +36,8 @@ PHP NEWS
by gcov. (Senthil)
- Opcache:
+ . Fixed bug #70991 (zend_file_cache.c:710: error: array type has incomplete
+ element type). (Laruence)
. Fixed bug #70977 (Segmentation fault with opcache.huge_code_pages=1).
(Laruence)
@@ -47,6 +49,8 @@ PHP NEWS
5.6). (Laruence)
- Standard:
+ . Fixed bug #70999 (php_random_bytes: called object is not a function).
+ (Scott)
. Fixed bug #70960 (ReflectionFunction for array_unique returns wrong number
of parameters). (Laruence)
diff --git a/ext/opcache/config.m4 b/ext/opcache/config.m4
index fbe18f8..497aa4c 100644
--- a/ext/opcache/config.m4
+++ b/ext/opcache/config.m4
@@ -26,6 +26,8 @@ if test "$PHP_OPCACHE" != "no"; then
AC_DEFINE(HAVE_MPROTECT, 1, [Define if you have mprotect() function])
])
+ AC_CHECK_HEADERS([unistd.h sys/uio.h])
+
AC_MSG_CHECKING(for sysvipc shared memory support)
AC_TRY_RUN([
#include <sys/types.h>
diff --git a/ext/opcache/zend_file_cache.c b/ext/opcache/zend_file_cache.c
index 7c615e9..993358b 100644
--- a/ext/opcache/zend_file_cache.c
+++ b/ext/opcache/zend_file_cache.c
@@ -706,7 +706,7 @@ int zend_file_cache_script_store(zend_persistent_script *script, int in_shm)
int fd;
char *filename;
zend_file_cache_metainfo info;
-#ifndef ZEND_WIN32
+#ifdef HAVE_SYS_UIO_H
struct iovec vec[3];
#endif
void *mem, *buf;
@@ -761,7 +761,7 @@ int zend_file_cache_script_store(zend_persistent_script *script, int in_shm)
info.checksum = zend_adler32(ADLER32_INIT, buf, script->size);
info.checksum = zend_adler32(info.checksum, (signed char*)ZSTR_VAL((zend_string*)ZCG(mem)),
info.str_size);
-#ifndef ZEND_WIN32
+#ifdef HAVE_SYS_UIO_H
vec[0].iov_base = &info;
vec[0].iov_len = sizeof(info);
vec[1].iov_base = buf;