Commit Graph

651 Commits

Author SHA1 Message Date
Peter Kokot
f1d7e3ca0b Sync leading and final newlines in *.phpt sections
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines in all
*.phpt sections.

According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.

C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."

Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
2018-10-15 04:31:31 +02:00
Peter Kokot
17ccbeec32 Trim trailing whitespace in *.phpt 2018-10-14 19:44:14 +02:00
Peter Kokot
60a69daec6 Sync leading and final newlines in source code files
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines.

According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.

C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."

Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
2018-10-14 12:54:08 +02:00
Peter Kokot
102cf75eeb Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
  Fix failing ext/zlib/tests due to whitespace
2018-10-13 15:15:39 +02:00
Peter Kokot
9120e79e9f Fix failing ext/zlib/tests due to whitespace 2018-10-13 15:15:26 +02:00
Peter Kokot
902d39a3a7 Trim trailing whitespace in source code files 2018-10-13 14:14:50 +02:00
Peter Kokot
7f6387b59a Trim trailing whitespace in source code files 2018-10-13 14:12:55 +02:00
Christoph M. Becker
fa70b91a4f Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
  Fix #75273: php_zlib_inflate_filter() may not update bytes_consumed
2018-09-08 19:09:56 +02:00
Christoph M. Becker
90d863898c Fix #75273: php_zlib_inflate_filter() may not update bytes_consumed
Whenever we return with `PSFS_PASS_ON`, we need to update
`bytes_consumed` to not mislead the caller.  Instead of fixing the
respective `if` clauses, we eschew the early bail-outs to simplify the
code a bit.
2018-09-08 19:01:36 +02:00
Peter Kokot
fab7d9f577 Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
  Fix bug #76709: Minimal required zlib library is 1.2.0.4
2018-08-06 09:39:33 +02:00
Peter Kokot
a3e3d914ed Fix bug #76709: Minimal required zlib library is 1.2.0.4
The minimal required version of zlib system library is 1.2.0.4 instead
of 1.0.9 as reported in the ./configure --help.
2018-08-06 09:37:16 +02:00
Peter Kokot
eceecb6900 Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
  Fix bug #65988: Zlib version check fails
2018-08-06 06:15:51 +02:00
Jay Bonci
c8a90606c1 Fix bug #65988: Zlib version check fails
When an 'include/zlib/' style dir is passed to --with-zlib configure
option the zlib version check fails.
2018-08-06 06:14:11 +02:00
Xinchen Hui
7a7ec01a49 year++ 2018-01-02 12:55:14 +08:00
Xinchen Hui
ccd4716ec7 year++ 2018-01-02 12:53:31 +08:00
Christoph M. Becker
1f150fcde1 Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
  Fix Bug #75299 Wrong reflection on inflate_init and inflate_add
2017-10-11 17:30:45 +02:00
Christoph M. Becker
d3d23e0cb8 Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  Fix Bug #75299 Wrong reflection on inflate_init and inflate_add
2017-10-11 17:29:36 +02:00
Fabien Villepinte
9d9873b3b5 Fix Bug #75299 Wrong reflection on inflate_init and inflate_add 2017-10-01 11:27:16 +02:00
Anatol Belski
07c7445dd0 fix datatype 2017-07-10 17:34:58 +02:00
Anatol Belski
7360e6a36f Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  Revert "Add more constants, improve comments, and add tests"
2017-07-10 17:01:25 +02:00
Anatol Belski
a797421e98 Revert "Add more constants, improve comments, and add tests"
This reverts commit 0c4f11ecaa.
2017-07-10 16:53:56 +02:00
Tom Van Looy
04fb3f28ff Remove superfluous semicolons 2017-06-26 00:23:25 +02:00
Bob Weinand
a1755671e2 Merge branch 'PHP-7.1' 2017-06-25 20:15:31 +02:00
Bob Weinand
44d734254a Merge branch 'PHP-7.0' into PHP-7.1 2017-06-25 20:13:48 +02:00
Matthew Trescott
0c4f11ecaa Add more constants, improve comments, and add tests 2017-06-25 20:12:45 +02:00
Nikita Popov
191f154d40 Merge branch 'PHP-7.1' 2017-06-25 15:32:38 +02:00
Nikita Popov
bda0f4e8dc Merge branch 'PHP-7.0' into PHP-7.1 2017-06-25 15:30:29 +02:00
wapmorgan
cd1869bcf2 Remove invalid check of dictionary content and add initialization of dictionary if raw compression used 2017-06-25 10:53:28 +02:00
Anatol Belski
f3c4e2f5bf extend zlib export required for the recent libpng 2017-04-23 21:33:14 +02:00
Anatol Belski
103ebbcb7a yet one more export required from newer zlib 2017-04-23 21:29:40 +02:00
Anatol Belski
bbd37771f6 Merge branch 'PHP-7.1'
* PHP-7.1:
  extend zlib export required for the recent libpng
2017-04-23 21:29:04 +02:00
Anatol Belski
144ddd3b42 Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  extend zlib export required for the recent libpng
2017-04-23 21:28:26 +02:00
Anatol Belski
2909742326 extend zlib export required for the recent libpng 2017-04-23 21:27:34 +02:00
Anatol Belski
ba64ec0b13 improve zlib version check for tests 2017-03-22 11:08:38 +01:00
Anatol Belski
f258e9b803 make test more flexible to match different compressed strings
particurarly needed with zlib 1.2.11
2017-03-22 11:08:37 +01:00
Bob Weinand
8a7a1411b9 Merge branch 'PHP-7.1' 2017-03-15 00:09:59 +01:00
Bob Weinand
f3ab4c1a08 Merge branch 'PHP-7.0' into PHP-7.1 2017-03-15 00:09:42 +01:00
Matt Bonneau
7fba8bda4c Fixed bug #74240 (deflate_add can allocate too much memory) 2017-03-15 00:08:32 +01:00
Nikita Popov
f25f469088 Merge branch 'PHP-7.1' 2017-01-08 13:48:54 +01:00
Nikita Popov
b38e6a54cf Merge branch 'PHP-7.0' into PHP-7.1 2017-01-08 13:48:48 +01:00
Nikita Popov
b36f4ac708 deflate_add(): Don't add unnecessary +1 to size
zend_string_realloc will do this by itself.
2017-01-08 13:47:20 +01:00
Sammy Kaye Powers
dac6c639bb Update copyright headers to 2017 2017-01-04 11:23:42 -06:00
Sammy Kaye Powers
478f119ab9 Update copyright headers to 2017 2017-01-04 11:14:55 -06:00
Sammy Kaye Powers
9e29f841ce Update copyright headers to 2017 2017-01-02 09:30:12 -06:00
Bob Weinand
712c532ab9 Merge branch 'PHP-7.1' 2016-12-22 15:31:58 +01:00
Bob Weinand
898e439333 Merge branch 'PHP-7.0' into PHP-7.1 2016-12-22 15:31:39 +01:00
Bob Weinand
8823b68c41 Fixed bug #73373 (deflate_add does not verify that output was not truncated) 2016-12-22 15:29:36 +01:00
Pedro Magalhães
9c5af4e4cb Remove the b prefix from literals on unrelated tests 2016-11-20 21:11:53 +01:00
Anatol Belski
42b7912f03 catch up with stream datatypes 2016-10-05 22:53:21 +02:00
Christoph M. Becker
c2b29a58bc Merge branch 'PHP-7.0' 2016-07-04 03:20:01 +02:00