From a87e38229921b48c32187c672a942516722f1b52 Mon Sep 17 00:00:00 2001 From: Jacek Antonelli Date: Sun, 11 Jan 2009 16:10:39 -0600 Subject: Second Life viewer sources 1.22.5-RC --- linden/indra/newview/lleventpoll.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'linden/indra/newview/lleventpoll.cpp') diff --git a/linden/indra/newview/lleventpoll.cpp b/linden/indra/newview/lleventpoll.cpp index 6b95102..845ae97 100644 --- a/linden/indra/newview/lleventpoll.cpp +++ b/linden/indra/newview/lleventpoll.cpp @@ -4,7 +4,7 @@ * * $LicenseInfo:firstyear=2006&license=viewergpl$ * - * Copyright (c) 2006-2008, Linden Research, Inc. + * Copyright (c) 2006-2009, Linden Research, Inc. * * Second Life Viewer Source Code * The source code in this file ("Source Code") is provided by Linden Lab -- cgit v1.1 From 0ef11cf31364456ec247b0fc7ad8f6d1de408400 Mon Sep 17 00:00:00 2001 From: Jacek Antonelli Date: Wed, 28 Jan 2009 20:04:52 -0600 Subject: Second Life viewer sources 1.22.6-RC --- linden/indra/newview/lleventpoll.cpp | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) (limited to 'linden/indra/newview/lleventpoll.cpp') diff --git a/linden/indra/newview/lleventpoll.cpp b/linden/indra/newview/lleventpoll.cpp index 845ae97..995c4e4 100644 --- a/linden/indra/newview/lleventpoll.cpp +++ b/linden/indra/newview/lleventpoll.cpp @@ -31,9 +31,9 @@ #include "llviewerprecompiledheaders.h" +#include "lleventpoll.h" #include "llappviewer.h" #include "llagent.h" -#include "lleventpoll.h" #include "llhttpclient.h" #include "llhttpstatuscodes.h" @@ -41,6 +41,7 @@ #include "lltimer.h" #include "llviewerregion.h" #include "message.h" +#include "lltrans.h" namespace { @@ -225,11 +226,15 @@ namespace // They are essentially disconnected from the region even though some things may still work. // Since things won't get better until they relog we force a disconnect now. - // *NOTE:Mani - This force disconnect was causing logouts even when disconnected - // from neighboring regions. - // *FIX:Mani We may want to re enable forceDisconnect for the agents main region. - // *FIX:Mani If reimplemting Translate!!!! - // LLAppViewer::instance()->forceDisconnect("You have been disconnected from the region you were in."); + // *NOTE:Mani - The following condition check to see if this failing event poll + // is attached to the Agent's main region. If so we disconnect the viewer. + // Else... its a child region and we just leave the dead event poll stopped and + // continue running. + if(gAgent.getRegion() && gAgent.getRegion()->getHost().getIPandPort() == mSender) + { + llwarns << "Forcing disconnect due to stalled main region event poll." << llendl; + LLAppViewer::instance()->forceDisconnect(LLTrans::getString("AgentLostConnection")); + } } } -- cgit v1.1