From 14a4b876e396af464390ec28b73d033d64276b0b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 31 May 2015 21:10:56 +0200 Subject: [PATCH] fix a possible NRE --- OpenRA.Mods.Common/Widgets/Logic/Ingame/GameTimerLogic.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/OpenRA.Mods.Common/Widgets/Logic/Ingame/GameTimerLogic.cs b/OpenRA.Mods.Common/Widgets/Logic/Ingame/GameTimerLogic.cs index f1cf7ae764..5fbdb7fab4 100644 --- a/OpenRA.Mods.Common/Widgets/Logic/Ingame/GameTimerLogic.cs +++ b/OpenRA.Mods.Common/Widgets/Logic/Ingame/GameTimerLogic.cs @@ -61,7 +61,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic var connection = orderManager.Connection as ReplayConnection; if (connection != null && connection.TickCount != 0) percentage.GetText = () => "({0}%)".F(orderManager.NetFrameNumber * 100 / connection.TickCount); - else + else if (timer != null) timer.Bounds.Width += percentage.Bounds.Width; } }