Compare commits

...
Author SHA1 Message Date
Joe Watkins 47b1a36a00 Revert "Add test for bug 75577: issue where RFC3339_EXTENDED could not be used via DateTime::createFromFormat (#2945)"
This reverts commit ff385755a5.
2021-05-10 13:17:55 +02:00
Mariano Iglesias ff385755a5 Add test for bug 75577: issue where RFC3339_EXTENDED could not be used via DateTime::createFromFormat (#2945)
* Adding test for bug 75577
2021-05-10 13:10:04 +02:00
Remi Collet c950e9807c Update NEWS for PHP 7.2.0 2017-11-28 09:08:22 +00:00
Remi Collet 94a750fcf6 drop -dev from Zend version 2017-11-28 08:00:45 +01:00
Remi Collet fe76e60f8d unset date (will be set by release process script) 2017-11-28 07:50:41 +01:00
Remi Collet 5b7cc8a8ac Prepare NEWS file for release
- set release date
- merge all alpha/beta/RC entries
- clean entries already in 7.1
2017-11-27 12:47:05 +01:00
Remi Collet b2014cd54d add 7.1 NEW entries 2017-11-23 11:11:15 +01:00
Remi Collet 57e5ba662d NEWS 2017-11-15 15:33:09 +01:00
Sara Golemon 96016087a4 Bugfix#75515 php://streams behaving greedily
5060fc23 attempted to fix #68948 by treating all non-uri streams
as non-blocking, however php://fd/* streams (which includes stdin)
may block if the other end of the IPC isn't finished.

This represents a partial revert to the pre RC6 state,
but includes an escape hatch for php://memory and php://temp
streams which are local to the current process.

This also restores stream_set_chunk_size test to previous state.
2017-11-15 15:31:09 +01:00
Derick Rethans caa630a7fe Revert "date module, replacing abs call with the llabs's like one due to bigger type"
This reverts commit c189845951.
2017-11-07 15:58:55 +01:00
Sara Golemon 7beb96ee4c Update NEWS for 7.2.0 2017-11-07 11:58:59 +00:00
Sara Golemon 29cd6eb799 Update NEWS for PHP 7.2.0RC6 2017-11-07 11:33:56 +00:00
5 changed files with 1693 additions and 601 deletions

No files matched your search

+1676 -585
View File
File diff suppressed because it is too large. Load diff
+1 -1
View File
@@ -22,7 +22,7 @@
#ifndef ZEND_H
#define ZEND_H
#define ZEND_VERSION "3.2.0-dev"
#define ZEND_VERSION "3.2.0"
#define ZEND_ENGINE_3
+6 -6
View File
@@ -2290,8 +2290,8 @@ static HashTable *date_object_get_properties(zval *object) /* {{{ */
ZSTR_LEN(tmpstr) = snprintf(ZSTR_VAL(tmpstr), sizeof("+05:00"), "%c%02d:%02d",
utc_offset < 0 ? '-' : '+',
php_date_llabs(utc_offset / 3600),
php_date_llabs(((utc_offset % 3600) / 60)));
abs(utc_offset / 3600),
abs(((utc_offset % 3600) / 60)));
ZVAL_NEW_STR(&zv, tmpstr);
}
@@ -2382,8 +2382,8 @@ static HashTable *date_object_get_properties_timezone(zval *object) /* {{{ */
ZSTR_LEN(tmpstr) = snprintf(ZSTR_VAL(tmpstr), sizeof("+05:00"), "%c%02d:%02d",
tzobj->tzi.utc_offset < 0 ? '-' : '+',
php_date_llabs(tzobj->tzi.utc_offset / 3600),
php_date_llabs(((tzobj->tzi.utc_offset % 3600) / 60)));
abs(tzobj->tzi.utc_offset / 3600),
abs(((tzobj->tzi.utc_offset % 3600) / 60)));
ZVAL_NEW_STR(&zv, tmpstr);
}
@@ -3912,8 +3912,8 @@ PHP_FUNCTION(timezone_name_get)
ZSTR_LEN(tmpstr) = snprintf(ZSTR_VAL(tmpstr), sizeof("+05:00"), "%c%02d:%02d",
utc_offset < 0 ? '-' : '+',
php_date_llabs(utc_offset / 3600),
php_date_llabs(((utc_offset % 3600) / 60)));
abs(utc_offset / 3600),
abs(((utc_offset % 3600) / 60)));
RETURN_NEW_STR(tmpstr);
}
@@ -39,7 +39,7 @@ var_dump(fwrite($f, str_repeat('b', 3)));
echo "should return previous chunk size (1)\n";
var_dump(stream_set_chunk_size($f, 100));
echo "should elicit 3 reads of size 100 (chunk size)\n";
echo "should elicit one read of size 100 (chunk size)\n";
var_dump(strlen(fread($f, 250)));
echo "should elicit one read of size 100 (chunk size)\n";
var_dump(strlen(fread($f, 50)));
@@ -67,15 +67,13 @@ write with size: 1
int(3)
should return previous chunk size (1)
int(1)
should elicit 3 reads of size 100 (chunk size)
read with size: 100
read with size: 100
read with size: 100
int(250)
should elicit one read of size 100 (chunk size)
read with size: 100
int(100)
should elicit one read of size 100 (chunk size)
read with size: 100
int(50)
should elicit no read because there is sufficient cached data
read with size: 100
int(50)
should elicit 2 writes of size 100 and one of size 50
write with size: 100
+5 -2
View File
@@ -24,6 +24,7 @@
#define _GNU_SOURCE
#include "php.h"
#include "php_globals.h"
#include "php_memory_streams.h"
#include "php_network.h"
#include "php_open_temporary_file.h"
#include "ext/standard/file.h"
@@ -709,8 +710,10 @@ PHPAPI size_t _php_stream_read(php_stream *stream, char *buf, size_t size)
break;
}
/* just break anyway, to avoid greedy read */
if (!stream->wrapper || stream->wrapper->is_url) {
/* just break anyway, to avoid greedy read for file://, php://memory, and php://temp */
if ((stream->wrapper != &php_plain_files_wrapper) &&
(stream->ops != &php_stream_memory_ops) &&
(stream->ops != &php_stream_temp_ops)) {
break;
}
}