AMMediaboard: Replace bind PanicAlert with OSD message

This commit is contained in:
Sepalani 2026-02-20 02:43:17 +04:00
parent 9323074ada
commit 989586433a

View File

@ -29,6 +29,7 @@
#include "Core/System.h"
#include "DiscIO/CachedBlob.h"
#include "VideoCommon/OnScreenDisplay.h"
#if defined(__linux__) or defined(__APPLE__) or defined(__FreeBSD__) or defined(__NetBSD__) or \
defined(__HAIKU__)
@ -923,12 +924,12 @@ static u32 NetDIMMBind(GuestSocket guest_socket, const GuestSocketAddress& guest
if (bind_result < 0)
{
const auto* const err_msg = Common::DecodeNetworkError(err);
ERROR_LOG_FMT(AMMEDIABOARD, "NetDIMMBind bind() = {} ({})", err, err_msg);
PanicAlertFmt("Failed to bind socket {}:{}\nError: {} ({})",
Common::IPAddressToString(adjusted_ipv4port.ip_address),
ntohs(adjusted_ipv4port.port), err, err_msg);
const auto msg = fmt::format("Failed to bind socket {}:{}",
Common::IPAddressToString(adjusted_ipv4port.ip_address),
ntohs(adjusted_ipv4port.port));
ERROR_LOG_FMT(AMMEDIABOARD, "NetDIMMBind: {} with error {}: {}", msg, err,
Common::DecodeNetworkError(err));
OSD::AddMessage(msg, OSD::Duration::SHORT, OSD::Color::RED);
}
return bind_result;