summaryrefslogtreecommitdiff
path: root/ext/sockets
diff options
context:
space:
mode:
authorChristoph M. Becker <cmbecker69@gmx.de>2020-11-12 14:58:47 +0100
committerChristoph M. Becker <cmbecker69@gmx.de>2020-11-12 16:42:28 +0100
commita08a2b48b489572db89940027206020ee714afa5 (patch)
tree7f612cfa39f9ac4d78b22e2ad25f32879b729776 /ext/sockets
parent34dd032e4e70a33e3e8fa27e38af62f63601b447 (diff)
downloadphp-git-a08a2b48b489572db89940027206020ee714afa5.tar.gz
Strip trailing line breaks and periods from Windows error messages
PHP error messages should not contain line breaks, so we remove these from the Windows specific error messages. We also remove trailing periods for the same reason. Closes GH-6423.
Diffstat (limited to 'ext/sockets')
-rw-r--r--ext/sockets/tests/socket_clear_error-win32.phpt3
-rw-r--r--ext/sockets/tests/socket_export_stream-4-win.phpt6
-rw-r--r--ext/sockets/tests/socket_import_stream-4-win.phpt6
-rw-r--r--ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp-win32.phpt3
-rw-r--r--ext/sockets/tests/socket_shutdown-win32.phpt6
-rw-r--r--ext/sockets/tests/wsaprotocol_info_0.phpt3
6 files changed, 9 insertions, 18 deletions
diff --git a/ext/sockets/tests/socket_clear_error-win32.phpt b/ext/sockets/tests/socket_clear_error-win32.phpt
index c875cfd2e8..901510c4f6 100644
--- a/ext/sockets/tests/socket_clear_error-win32.phpt
+++ b/ext/sockets/tests/socket_clear_error-win32.phpt
@@ -26,7 +26,6 @@ unset($socket);
unset($socketConn);
?>
--EXPECTF--
-Warning: socket_connect(): unable to connect [%d]: No connection could be made because the target machine actively refused it.
- in %s on line %d
+Warning: socket_connect(): unable to connect [%d]: No connection could be made because the target machine actively refused it in %s on line %d
int(%d)
int(%d)
diff --git a/ext/sockets/tests/socket_export_stream-4-win.phpt b/ext/sockets/tests/socket_export_stream-4-win.phpt
index fddd459a7d..4a35394699 100644
--- a/ext/sockets/tests/socket_export_stream-4-win.phpt
+++ b/ext/sockets/tests/socket_export_stream-4-win.phpt
@@ -94,12 +94,10 @@ close stream
stream_set_blocking TypeError: stream_set_blocking(): supplied resource is not a valid stream resource
socket_set_block
-Warning: socket_set_block(): unable to set blocking mode [%d]: An operation was attempted on something that is not a socket.
- in %s on line %d
+Warning: socket_set_block(): unable to set blocking mode [%d]: An operation was attempted on something that is not a socket in %s on line %d
socket_get_option
-Warning: socket_get_option(): Unable to retrieve socket option [%d]: An operation was attempted on something that is not a socket.
- in %s on line %d
+Warning: socket_get_option(): Unable to retrieve socket option [%d]: An operation was attempted on something that is not a socket in %s on line %d
diff --git a/ext/sockets/tests/socket_import_stream-4-win.phpt b/ext/sockets/tests/socket_import_stream-4-win.phpt
index 94af0ab5c1..3b0386246e 100644
--- a/ext/sockets/tests/socket_import_stream-4-win.phpt
+++ b/ext/sockets/tests/socket_import_stream-4-win.phpt
@@ -89,12 +89,10 @@ close stream
stream_set_blocking TypeError: stream_set_blocking(): supplied resource is not a valid stream resource
socket_set_block
-Warning: socket_set_block(): unable to set blocking mode [10038]: %s
- in %ssocket_import_stream-4-win.php on line %d
+Warning: socket_set_block(): unable to set blocking mode [10038]: %s in %ssocket_import_stream-4-win.php on line %d
socket_get_option
-Warning: socket_get_option(): Unable to retrieve socket option [10038]: %s
- in %ssocket_import_stream-4-win.php on line %d
+Warning: socket_get_option(): Unable to retrieve socket option [10038]: %s in %ssocket_import_stream-4-win.php on line %d
diff --git a/ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp-win32.phpt b/ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp-win32.phpt
index 9a686539da..813cb94b11 100644
--- a/ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp-win32.phpt
+++ b/ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp-win32.phpt
@@ -46,8 +46,7 @@ require 'ipv6_skipif.inc';
socket_close($socket);
?>
--EXPECTF--
-Warning: socket_recvfrom(): unable to recvfrom [10022]: %s
- in %s on line %d
+Warning: socket_recvfrom(): unable to recvfrom [10022]: %s in %s on line %d
Received Ping! from remote address ::1 and remote port 1223
--CREDITS--
Falko Menge <mail at falko-menge dot de>
diff --git a/ext/sockets/tests/socket_shutdown-win32.phpt b/ext/sockets/tests/socket_shutdown-win32.phpt
index cc16c3a215..cc11b6176d 100644
--- a/ext/sockets/tests/socket_shutdown-win32.phpt
+++ b/ext/sockets/tests/socket_shutdown-win32.phpt
@@ -50,10 +50,8 @@ bool(true)
bool(true)
bool(true)
-Warning: socket_shutdown(): Unable to shutdown socket [%d]: A request to send or receive data was disallowed because the socket is not connected and (when sending on a datagram socket using a sendto call) no address was supplied.
- in %s on line %d
+Warning: socket_shutdown(): Unable to shutdown socket [%d]: A request to send or receive data was disallowed because the socket is not connected and (when sending on a datagram socket using a sendto call) no address was supplied in %s on line %d
bool(false)
-Warning: socket_shutdown(): Unable to shutdown socket [%d]: An invalid argument was supplied.
- in %s on line %d
+Warning: socket_shutdown(): Unable to shutdown socket [%d]: An invalid argument was supplied in %s on line %d
bool(false)
diff --git a/ext/sockets/tests/wsaprotocol_info_0.phpt b/ext/sockets/tests/wsaprotocol_info_0.phpt
index 2d189d55bc..a932c51646 100644
--- a/ext/sockets/tests/wsaprotocol_info_0.phpt
+++ b/ext/sockets/tests/wsaprotocol_info_0.phpt
@@ -57,7 +57,6 @@ object(Socket)#%d (0) {
object(Socket)#%d (0) {
}
-Warning: socket_wsaprotocol_info_export(): Unable to export WSA protocol info [0x00002726]: %s
- in %s on line %d
+Warning: socket_wsaprotocol_info_export(): Unable to export WSA protocol info [0x00002726]: %s in %s on line %d
Warning: socket_wsaprotocol_info_import(): Unable to open file mapping [0x00000002] in %s on line %d