Skip to content

Commit 4c873df

Browse files
devnexennikic
authored andcommitted
sockets enabling SO_MARK socket option which is relatively similar
to FreeBSD's SO_USER_COOKIE giving a socket an identifier for packet filter, giving a specific route table.
1 parent b3e0888 commit 4c873df

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

ext/sockets/sockets.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -547,6 +547,9 @@ static PHP_MINIT_FUNCTION(sockets)
547547
#endif
548548
REGISTER_LONG_CONSTANT("SOL_SOCKET", SOL_SOCKET, CONST_CS | CONST_PERSISTENT);
549549
REGISTER_LONG_CONSTANT("SOMAXCONN", SOMAXCONN, CONST_CS | CONST_PERSISTENT);
550+
#ifdef SO_MARK
551+
REGISTER_LONG_CONSTANT("SO_MARK", SO_MARK, CONST_CS | CONST_PERSISTENT);
552+
#endif
550553
#ifdef TCP_NODELAY
551554
REGISTER_LONG_CONSTANT("TCP_NODELAY", TCP_NODELAY, CONST_CS | CONST_PERSISTENT);
552555
#endif

0 commit comments

Comments
 (0)