mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
sockets add AF_DIVERT constant.
Allow to bind a socket to a divert port without being concerned by its address. for ipfw filter purpose (SO_USER_COOKIE constant). FreeBSD only. Close GH-10415.
This commit is contained in:
parent
cf1d21edbd
commit
f8f7fd2db1
4 changed files with 13 additions and 1 deletions
1
NEWS
1
NEWS
|
@ -94,6 +94,7 @@ PHP NEWS
|
|||
. Added TCP_QUICKACK constant, to give tigher control over
|
||||
ACK delays. (David Carlier)
|
||||
. Added DONTFRAGMENT support for path MTU discovery purpose. (David Carlier)
|
||||
. Added AF_DIVERT for raw socket for divert ports. (David Carlier)
|
||||
|
||||
- Standard:
|
||||
. E_NOTICEs emitted by unserialize() have been promoted to E_WARNING. (timwolla)
|
||||
|
|
|
@ -132,6 +132,7 @@ PHP 8.3 UPGRADE NOTES
|
|||
. IP_PMTUDISC_PROBE (Linux only).
|
||||
. IP_PMTUDISC_INTERFACE (Linux only).
|
||||
. IP_PMTUDISC_OMIT (Linux only).
|
||||
. AF_DIVERT (FreeBSD only).
|
||||
|
||||
========================================
|
||||
11. Changes to INI File Handling
|
||||
|
|
|
@ -19,6 +19,13 @@ const AF_INET = UNKNOWN;
|
|||
*/
|
||||
const AF_INET6 = UNKNOWN;
|
||||
#endif
|
||||
#ifdef AF_DIVERT
|
||||
/**
|
||||
* @var int
|
||||
* @cvalue AF_DIVERT
|
||||
*/
|
||||
const AF_DIVERT = UNKNOWN;
|
||||
#endif
|
||||
/**
|
||||
* @var int
|
||||
* @cvalue SOCK_STREAM
|
||||
|
|
5
ext/sockets/sockets_arginfo.h
generated
5
ext/sockets/sockets_arginfo.h
generated
|
@ -1,5 +1,5 @@
|
|||
/* This is a generated file, edit the .stub.php file instead.
|
||||
* Stub hash: add91c303eddf7518566bc7e6c1698d7198c0d4c */
|
||||
* Stub hash: bf1d22072bd147128a33d82f8b3fc441cf95156a */
|
||||
|
||||
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_socket_select, 0, 4, MAY_BE_LONG|MAY_BE_FALSE)
|
||||
ZEND_ARG_TYPE_INFO(1, read, IS_ARRAY, 1)
|
||||
|
@ -340,6 +340,9 @@ static void register_sockets_symbols(int module_number)
|
|||
REGISTER_LONG_CONSTANT("AF_INET", AF_INET, CONST_PERSISTENT);
|
||||
#if HAVE_IPV6
|
||||
REGISTER_LONG_CONSTANT("AF_INET6", AF_INET6, CONST_PERSISTENT);
|
||||
#endif
|
||||
#if defined(AF_DIVERT)
|
||||
REGISTER_LONG_CONSTANT("AF_DIVERT", AF_DIVERT, CONST_PERSISTENT);
|
||||
#endif
|
||||
REGISTER_LONG_CONSTANT("SOCK_STREAM", SOCK_STREAM, CONST_PERSISTENT);
|
||||
REGISTER_LONG_CONSTANT("SOCK_DGRAM", SOCK_DGRAM, CONST_PERSISTENT);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue