修复 一点小BUG

This commit is contained in:
2026-01-13 10:54:15 +08:00
parent fd3dd8dfbe
commit b48907796f
3 changed files with 20 additions and 4 deletions

View File

@@ -286,7 +286,23 @@ namespace LogCap.Common
{
return;
}
long HHH = context.SystemHeader.Value.HostNumber.ToHotelCode();
long HHH = 0;
var abd = context.SystemHeader.HasValue;
if (abd == false)
{
return;
}
try
{
HHH = context.SystemHeader.Value.HostNumber.ToHotelCode();
}
catch (Exception)
{
var data_error= Tools.ByteToString(data.ToArray());
Console.WriteLine("ErrorData"+data_error);
return;
}
var list = Program.Cache.Get<List<Monitor_Host>>(CacheKey.Key);
@@ -373,7 +389,7 @@ namespace LogCap.Common
string Key = string.Format("{0}_{1}", CacheKey.RoomIP_Port_Prefix, HostNNN);
var takeMM = Program.Cache.Get<MonitorRedis>(Key);
if (HHH == 1197)
{
//Console.WriteLine("1197::::"+JsonConvert.SerializeObject(takeMM));