Commit Graph

4943 Commits

Author SHA1 Message Date
Nikita Popov
7f6c22cb3d Fix last maybe uninit warnings on 7.4
Most of these only occur under GCC 5. Not fond of all the workarounds
(especially the PDO one), but it gets us a clean build...
2019-04-15 11:35:13 +02:00
George Wang
f0f1388d60 Merge branch 'PHP-7.3' into PHP-7.4 2019-04-12 17:48:22 -04:00
George Wang
7f551c728c Merge branch 'PHP-7.2' into PHP-7.3 2019-04-12 17:44:32 -04:00
George Wang
1e7f1b90e8 LiteSpeed SAPI 7.3, better process management, new API function litespeed_finish_request(). 2019-04-12 17:43:45 -04:00
Nikita Popov
3c23084cf6 Fix strict aliasing violation in phpdbg
By explicitly computing the message length from bytes. This also
makes sure that the length is interpreted in an endianness-independent
manner.
2019-04-12 16:46:23 +02:00
Nikita Popov
c09b63595e Fix potentially uninitialized warnings in phpdbg 2019-04-12 11:46:03 +02:00
Dmitry Stogov
55cc280429 Backported call frame initialization improvement 2019-04-12 02:35:42 +03:00
Nikita Popov
09b2e20333 Work around -Walloc-size-larger-than bug 2019-04-11 17:44:20 +02:00
Nikita Popov
d087a356fe Suppress warnings using zend_quiet_write 2019-04-11 12:22:52 +02:00
Peter Kokot
6acba73876 Add AS_HELP_STRING to phpdbg options 2019-04-07 23:24:10 +02:00
Peter Kokot
e06836a1a3 Remove checks for locale.h, setlocale, localeconv
The `<loccale.h>` header file, setlocale, and localeconv are part of the
standard C89 [1] and on current systems can be used unconditionally.

Since PHP 7.4 requires at least C89 or greater, the `HAVE_LOCALE_H`,
`HAVE_SETLOCALE`, and `HAVE_LOCALECONV` symbols defined by Autoconf in
configure.ac [2] can be ommitted and simplifed.

The bundled libmagic (file) has also been patched already in version
5.35 and up in upstream location so when it will be patched also in
php-src the check for locale.h header is still left in the configure.ac
and in windows headers definition file.

[1] https://port70.net/~nsz/c/c89/c89-draft.html#4.4
[2] https://git.savannah.gnu.org/cgit/autoconf.git/tree/lib/autoconf/headers.m4

Omit the bundled libmagic files
2019-04-07 18:32:54 +02:00
Peter Kokot
5f8915786f Remove HAVE_SIGNAL_H
The `<signal.h>` header file is part of the standard C89 headers [1] and
on current systems can be included unconditionally.

Since file requires at least C89 or greater, the `HAVE_SIGNAL_H` symbol
defined by Autoconf in Zend.m4 [2] can be ommitted and simplifed.

The bundled libmagic (file) also ommits the usage of HAVE_SIGNAL_H since
5.35 however current version in PHP is very modified 5.34 version and
will be refactored separately. Check for HAVE_SIGNAL_H is therefore
still done in the configure.ac.

Refs:
[1] https://port70.net/~nsz/c/c89/c89-draft.html#4.1.2
[2] https://git.savannah.gnu.org/cgit/autoconf.git/tree/lib/autoconf/headers.m4
2019-04-07 15:55:34 +02:00
Matteo Beccati
15ff5db6b9 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Ref #76801 remove old file source from file_sources hash in case of file included more than once
2019-04-03 14:36:20 +02:00
Matteo Beccati
9f02f9fd5c Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Ref #76801 remove old file source from file_sources hash in case of file included more than once
2019-04-03 14:36:11 +02:00
Alessandro Chitolina
4029c0b6a2 Ref #76801 remove old file source from file_sources hash in case of file included more than once 2019-04-03 14:35:57 +02:00
Joe Watkins
072eb6dd77
tsrm environment lock 2019-03-29 19:06:02 +01:00
Joe Watkins
330517987b
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  fix build: readline support must be disabled by default in phpdbg
2019-03-28 07:35:33 +01:00
Joe Watkins
62a652a0d5
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  fix build: readline support must be disabled by default in phpdbg
2019-03-28 07:35:15 +01:00
Joe Watkins
b7442f1bb8
fix build: readline support must be disabled by default in phpdbg 2019-03-28 07:34:45 +01:00
Joe Watkins
56293d0637
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #77805 phpdbg build fails when readline is shared
2019-03-27 10:04:36 +01:00
Joe Watkins
eb405a2192
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fix #77805 phpdbg build fails when readline is shared
2019-03-27 10:04:07 +01:00
Joe Watkins
7af270eb28
Fix #77805 phpdbg build fails when readline is shared 2019-03-27 10:02:42 +01:00
Joe Watkins
f177a2ac58
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  more work on phpdbg conditional breaks
2019-03-27 00:02:43 +01:00
Joe Watkins
1e4cff9ddb
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  more work on phpdbg conditional breaks
2019-03-27 00:02:31 +01:00
Joe Watkins
6d3a2b4693
more work on phpdbg conditional breaks 2019-03-27 00:02:15 +01:00
Joe Watkins
903c1e379b
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #77800 phpdbg segfaults on conditional breakpoints
2019-03-26 23:06:54 +01:00
Joe Watkins
e177d26d0e
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fix #77800 phpdbg segfaults on conditional breakpoints
2019-03-26 23:06:15 +01:00
Joe Watkins
7df8e4fc0a
Fix #77800 phpdbg segfaults on conditional breakpoints 2019-03-26 23:05:06 +01:00
Peter Kokot
0d2dadc0e2 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  [ci skip] Update NEWS
  [ci skip] Update NEWS
  Fix #77794: Incorrect Date header format in built-in server
2019-03-25 21:57:39 +01:00
Peter Kokot
58e00df9fe Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  [ci skip] Update NEWS
  Fix #77794: Incorrect Date header format in built-in server
2019-03-25 21:56:39 +01:00
Niklas Keller
7f9872387e Fix #77794: Incorrect Date header format in built-in server
- Fix the date format to be compliant with https://tools.ietf.org/html/rfc7231#section-7.1.1.2
- Fix date format length and use GMT time
- Previously, local time was used instead of GMT.
- Remove extra whitespace
- Simplify string appends in php_cli_server.c
2019-03-25 21:41:45 +01:00
Joe Watkins
994a897586
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  fix bug #76801: phpdbg too many open files error
2019-03-23 09:49:28 +01:00
Joe Watkins
93740a2482
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  fix bug #76801: phpdbg too many open files error
2019-03-23 09:48:20 +01:00
Alessandro Chitolina
b8b880932e
fix bug #76801: phpdbg too many open files error 2019-03-23 09:47:49 +01:00
Peter Kokot
864366ef20 Upgrade deprecated directives and use non-posix bison
With Bison 3.0 some directives are deprecated:
- %name-prefix "x" should be %define api.prefix {x}
- %error-verbose should be %define parse.error verbose

Bison 3.3 also started emiting more warnings and since PHP souce parsers
are not POSIX compliant this patch fixes this as pointed out via
495a46aa1d.
2019-03-19 20:29:20 +01:00
Nikita Popov
97bcfe54e7 Merge branch 'PHP-7.3' into PHP-7.4 2019-03-19 09:55:52 +01:00
Nikita Popov
20c261b2fe Merge branch 'PHP-7.2' into PHP-7.3 2019-03-19 09:55:42 +01:00
Miriam Lauter
09e522322a Fix #77767: phpdbg break command help message shows incorrect aliases
Previously the aliases for at and del were listed as A and d
in the help message for break. This patch corrects the aliases
to be @ and ~ respectively.
2019-03-19 09:55:10 +01:00
Fabien Villepinte
26dfce7f36 Replace dirname(__FILE__) by __DIR__ in tests 2019-03-15 22:55:30 +01:00
Peter Kokot
97d25c87d2 Clean build system
Changes:
- AC_TYPE_SIZE_T called on only one place (configure.ac)
- AC_FUNC_ALLOCA called on only one place (configure.ac)
- AC_TYPE_UID_T called on only one place (configure.ac)
- HAVE_STRSTR removed since strstr is part of C89 standard [1]
- Remove checks for strtol and strpbrk
- Checking for the presence of perror function is not needed anymore
  since it is part of C89 standard and PHP calls it unconditionally.
- Checking for functions strdup, setenv, strerror, and memmove done only
  on one place (configure.ac)
- outdated check for snprintf removed

1: https://port70.net/~nsz/c/c89/c89-draft.html
2019-03-14 20:20:12 +01:00
Dmitry Stogov
9499484ed2 Implemented a faster way to access predefined TSRM resources - CG(), EG(), etc. 2019-03-14 03:01:01 +03:00
Dmitry Stogov
04b67bac32 Avoid reinitailization of ZTS cache pointer. Initialize it once in TSRM.c 2019-03-12 17:35:50 +03:00
Dmitry Stogov
cf4ee57dc9 Fixed ZTS cache usage 2019-03-12 15:25:51 +03:00
Dmitry Stogov
25d4af9413 Fixed ZTS cache usage 2019-03-12 15:13:52 +03:00
Dmitry Stogov
b0d76ed4ad Fixed ZTS cache usage 2019-03-12 15:05:56 +03:00
Nikita Popov
5b778e852e Merge branch 'PHP-7.3' into PHP-7.4 2019-03-12 09:58:29 +01:00
Nikita Popov
a7739be22f Fixed bug #77722 2019-03-12 09:58:09 +01:00
Remi Collet
233888e36a use DL_LOAD in litespeed 2019-03-12 08:23:11 +01:00
Peter Kokot
9df6a1e4dd Add AS_HELP_STRING to *nix build configure options
The Autoconf's default AS_HELP_STRING macro can properly format help
strings [1] so watching out if columns are aligned manually is not
anymore.

[1] https://www.gnu.org/software/autoconf/manual/autoconf.html#Pretty-Help-Strings
2019-03-07 20:36:59 +01:00
Peter Kokot
bebcdcc745 Remove legacy AC_CHECK_TYPE calls for uint and ulong
The AC_CHECK_TYPE was refactored in more recent versions of Autoconf
and the call with two arguments is obsolete and not recommended anymore.

This patch also refactors some leftovers of using ulong and uint which
are not standard nor common usages of types in C.

The ulong can be used as zend_ulong and uint usage is actually
`unsigned int`.

The usage of HAVE_ULONG removed since it is not used in current code
base.

Legacy edgecase for some legacy HPUX systems removed:
- sys/stream.h header is not checked and the HAVE_SYS_STREAM_H is
  not defined with current build system.

- flags are unsigned int
- max_allowed_packet changed to unsigned int
2019-03-06 22:49:16 +01:00