mirror of
https://github.com/phpseclib/phpseclib.git
synced 2024-12-29 12:32:45 +00:00
SSH/Agent: use PHP8's new str_contains function
This commit is contained in:
parent
768d2be8f8
commit
efd5bf281a
@ -137,7 +137,7 @@ class Agent
|
||||
throw new RuntimeException("Unable to connect to ssh-agent (Error $errno: $errstr)");
|
||||
}
|
||||
} else {
|
||||
if (substr($address, 0, 9) != '\\\\.\\pipe\\' || strpos(substr($address, 9), '\\') !== false) {
|
||||
if (substr($address, 0, 9) != '\\\\.\\pipe\\' || str_contains(substr($address, 9), '\\')) {
|
||||
throw new RuntimeException('Address is not formatted as a named pipe should be');
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user