From 7c445da5355cdeb3b9e4f881c9fc464b0e62d42f Mon Sep 17 00:00:00 2001
From: dg <dg@51575b47-30f0-44d4-a5cc-537603b46e54>
Date: Thu, 15 Sep 2011 22:41:05 +0000
Subject: [PATCH] fix

git-svn-id: http://svn.net-core.org/repos/t-engine4@4415 51575b47-30f0-44d4-a5cc-537603b46e54
---
 game/modules/tome/dialogs/ShowChatLog.lua | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/game/modules/tome/dialogs/ShowChatLog.lua b/game/modules/tome/dialogs/ShowChatLog.lua
index fb50f254ab..3d22f4b906 100644
--- a/game/modules/tome/dialogs/ShowChatLog.lua
+++ b/game/modules/tome/dialogs/ShowChatLog.lua
@@ -156,7 +156,7 @@ function _M:switchTo(ui)
 		self:loadLog(self.log:getLog())
 	else
 		local s = nil
-		if _M.last_tab == ui.tab_channel and self.scroll < self.max - self.max_display + 1 then
+		if _M.last_tab == ui.tab_channel and self.max and self.max_display and self.scroll < self.max - self.max_display + 1 then
 			s = self.scroll
 		end
 		self:loadLog(self.chat:getLog(ui.tab_channel, true), s)
-- 
GitLab