INTEGRATION: CWS sb49 (1.6.20); FILE MERGED
2006/03/22 10:15:19 sb 1.6.20.1: #i63397# Keep objects alive long enough so that threads still running while atexit handlers are processed do not access dead objects.
This commit is contained in:
parent
0ae6a32269
commit
cbe41b9122
1 changed files with 5 additions and 4 deletions
|
@ -4,9 +4,9 @@
|
|||
*
|
||||
* $RCSfile: context.cxx,v $
|
||||
*
|
||||
* $Revision: 1.6 $
|
||||
* $Revision: 1.7 $
|
||||
*
|
||||
* last change: $Author: hr $ $Date: 2005-12-28 17:32:14 $
|
||||
* last change: $Author: hr $ $Date: 2006-04-19 13:44:21 $
|
||||
*
|
||||
* The Contents of this file are made available subject to
|
||||
* the terms of GNU Lesser General Public License Version 2.1.
|
||||
|
@ -176,8 +176,9 @@ ContextAdmin *ContextAdmin::getInstance()
|
|||
if( ! g_pTheContext ) {
|
||||
::osl::MutexGuard guard( ::osl::Mutex::getGlobalMutex() );
|
||||
if( ! g_pTheContext ) {
|
||||
static ContextAdmin admin;
|
||||
g_pTheContext = &admin;
|
||||
//TODO This memory is leaked; see #i63473# for when this should be
|
||||
// changed again:
|
||||
g_pTheContext = new ContextAdmin;
|
||||
}
|
||||
}
|
||||
return g_pTheContext;
|
||||
|
|
Loading…
Reference in a new issue