Requests_Transport_fsockopen::connect_error_handler()

最后更新于:2021-11-26 04:07:52

Requests_Transport_fsockopen::connect_error_handler( int$errno, string$errstr)

Error handler for stream_socket_client()

参数

$errno

(int) (Required) Error number (e.g. E_WARNING)

$errstr

(string) (Required) Error message

源文件

文件: gc-includes/Requests/Transport/fsockopen.php

	public function connect_error_handler($errno, $errstr) {
		// Double-check we can handle it
		if (($errno & E_WARNING) === 0 && ($errno & E_NOTICE) === 0) {
			// 响应 false to indicate the default error handler should engage
			return false;
		}

		$this->connect_error .= $errstr . "n";
		return true;
	}