From 82ab86d4a8e8596da3b10b88d55342d8d4d68324 Mon Sep 17 00:00:00 2001 From: hobsRKM Date: Wed, 24 Apr 2024 10:11:07 +0000 Subject: [PATCH] Enhance port detections --- app/Http/Controllers/ServerController.php | 4 ++-- body.md | 6 +----- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/app/Http/Controllers/ServerController.php b/app/Http/Controllers/ServerController.php index 06502ff..4127a9b 100755 --- a/app/Http/Controllers/ServerController.php +++ b/app/Http/Controllers/ServerController.php @@ -78,8 +78,8 @@ public function getAllServerInfo(RconService $rcon) private function isPortOpen($ip, $port, $timeout = 1) { $fp = @fsockopen($ip, $port, $errno, $errstr, $timeout); - if ($fp) { - fclose($fp); + if (!in_array($errno, [SOCKET_ETIMEDOUT,SOCKET_EHOSTUNREACH,SOCKET_ENETUNREACH]) && stripos(strtolower($errstr), 'failed') === false) { + $fp ? fclose($fp) : ''; return true; } else { return false; diff --git a/body.md b/body.md index 9cc427a..01b468a 100644 --- a/body.md +++ b/body.md @@ -1,9 +1,5 @@ -Release notes V 1.2.0 -## Important- This is major release for SimpleAdmin Support version 1.3.9 +Release notes V 1.2.3 -## Update your simpleAdmin to latest version - if you do not want to update , you simple ignore this and continue using panel, but this panel update has new features. -## Future olderversion support will be removed. # Update Log - Updated the panel to support latest version of cs2SimpleAdmin 1.3.9 - Added edit/mute ban , you can now edit banned/unbanned players form listing to extend bans or re add ban