summaryrefslogtreecommitdiff
path: root/indra/newview/llsecapi.cpp
diff options
context:
space:
mode:
authorKaren Lahey <karina@lindenlab.com>2009-10-15 16:52:03 -0700
committerKaren Lahey <karina@lindenlab.com>2009-10-15 16:52:03 -0700
commit73e86b0bed548b2aaba8d92837e562d6d753808a (patch)
treeee77d1f79fee430bb64c61d89988a0cb07ecf257 /indra/newview/llsecapi.cpp
parent7ab41a8a815968e274ebbfc459328be40cf5479a (diff)
MAC Address Change no longer causes viewer to die cr:Roxie
Diffstat (limited to 'indra/newview/llsecapi.cpp')
-rw-r--r--indra/newview/llsecapi.cpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/indra/newview/llsecapi.cpp b/indra/newview/llsecapi.cpp
index a928b4580e..ba343f5387 100644
--- a/indra/newview/llsecapi.cpp
+++ b/indra/newview/llsecapi.cpp
@@ -50,11 +50,33 @@ void initializeSecHandler()
OpenSSL_add_all_digests();
gHandlerMap[BASIC_SECHANDLER] = new LLSecAPIBasicHandler();
+
// Currently, we only have the Basic handler, so we can point the main sechandler
// pointer to the basic handler. Later, we'll create a wrapper handler that
// selects the appropriate sechandler as needed, for instance choosing the
// mac keyring handler, with fallback to the basic sechandler
gSecAPIHandler = gHandlerMap[BASIC_SECHANDLER];
+
+ // initialize all SecAPIHandlers
+ LLProtectedDataException ex = LLProtectedDataException("");
+ std::map<std::string, LLPointer<LLSecAPIHandler> >::const_iterator itr;
+ for(itr = gHandlerMap.begin(); itr != gHandlerMap.end(); ++itr)
+ {
+ LLPointer<LLSecAPIHandler> handler = (*itr).second;
+ try
+ {
+ handler->init();
+ }
+ catch (LLProtectedDataException e)
+ {
+ ex = e;
+ }
+ }
+ if (ex.getMessage().length() > 0 ) // an exception was thrown.
+ {
+ throw ex;
+ }
+
}
// start using a given security api handler. If the string is empty
// the default is used