summaryrefslogtreecommitdiff
path: root/ext/bz2
diff options
context:
space:
mode:
authorOndřej Surý <ondrej@sury.org>2014-04-17 11:11:51 +0200
committerOndřej Surý <ondrej@sury.org>2014-04-17 11:11:51 +0200
commit9566c3fcaf4cfaa866ea395ee5d1a480785fef0d (patch)
treed053b8b66afe080ea2250d5fbcdfc21c243d54ab /ext/bz2
parent30bdcf2392ef8cc7b8b4a07b49367571ae1db286 (diff)
downloadphp-9566c3fcaf4cfaa866ea395ee5d1a480785fef0d.tar.gz
New upstream version 5.6.0~beta1+dfsgupstream/5.6.0_beta1+dfsg
Diffstat (limited to 'ext/bz2')
-rw-r--r--ext/bz2/bz2.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/ext/bz2/bz2.c b/ext/bz2/bz2.c
index 2f440597b..cc845584f 100644
--- a/ext/bz2/bz2.c
+++ b/ext/bz2/bz2.c
@@ -31,6 +31,7 @@
#include "ext/standard/file.h"
#include "ext/standard/info.h"
#include "ext/standard/php_string.h"
+#include "main/php_network.h"
/* for fileno() */
#include <stdio.h>
@@ -245,7 +246,7 @@ PHP_BZ2_API php_stream *_php_stream_bz2open(php_stream_wrapper *wrapper,
stream = php_stream_open_wrapper(path, mode, options | STREAM_WILL_CAST, opened_path);
if (stream) {
- int fd;
+ php_socket_t fd;
if (SUCCESS == php_stream_cast(stream, PHP_STREAM_AS_FD, (void **) &fd, REPORT_ERRORS)) {
bz_file = BZ2_bzdopen(fd, mode);
}
@@ -394,7 +395,7 @@ static PHP_FUNCTION(bzopen)
NULL);
} else if (Z_TYPE_PP(file) == IS_RESOURCE) {
/* If it is a resource, than its a stream resource */
- int fd;
+ php_socket_t fd;
int stream_mode_len;
php_stream_from_zval(stream, file);