From f6bd5dcbe9d4e707bc61df154058e13d450cc267 Mon Sep 17 00:00:00 2001 From: "Christoph M. Becker" Date: Sat, 12 Oct 2019 16:27:24 +0200 Subject: [PATCH] Fix test case `MSG_EOR` and `MSG_EOF` are not necessarily defined, in which case the test would fail. --- ext/sockets/tests/socket_send.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/sockets/tests/socket_send.phpt b/ext/sockets/tests/socket_send.phpt index dd6be6898b8..71ba5b028f8 100644 --- a/ext/sockets/tests/socket_send.phpt +++ b/ext/sockets/tests/socket_send.phpt @@ -23,11 +23,11 @@ if(socket_send($socket, $stringSocket, $stringSocketLength, MSG_OOB)===$stringSo print("okey\n"); } -if(socket_send($socket, $stringSocket, $stringSocketLength, MSG_EOR)===$stringSocketLength){ +if(!defined('MSG_EOR') || socket_send($socket, $stringSocket, $stringSocketLength, MSG_EOR)===$stringSocketLength){ print("okey\n"); } -if(socket_send($socket, $stringSocket, $stringSocketLength, MSG_EOF)===$stringSocketLength){ +if(!defined('MSG_EOF') || socket_send($socket, $stringSocket, $stringSocketLength, MSG_EOF)===$stringSocketLength){ print("okey\n"); }