Since some platforms do string operations within local file ::Load, we shouldn't declare that objects being created/destroyed from static ctor/dtor is not legal throughout the entire ::Load function. That only needs to be true around the actual PR_LoadLibrary calls. Fixing this stops the ridiculous amount of warning output that we get from every debug mac build. Also removing unused old mac local file impls. b=326837 r=bsmedberg

git-svn-id: svn://10.0.0.236/trunk@215283 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
joshmoz%gmail.com
2006-11-14 22:06:00 +00:00
parent f8200ed000
commit a124bbcf35
7 changed files with 40 additions and 3718 deletions

View File

@@ -57,6 +57,7 @@
#include "MoreFilesX.h"
#include "FSCopyObject.h"
#include "nsAutoBuffer.h"
#include "nsTraceRefcntImpl.h"
// Mac Includes
#include <Carbon/Carbon.h>
@@ -1347,8 +1348,16 @@ NS_IMETHODIMP nsLocalFile::Load(PRLibrary **_retval)
if (NS_FAILED(rv))
return rv;
#ifdef NS_BUILD_REFCNT_LOGGING
nsTraceRefcntImpl::SetActivityIsLegal(PR_FALSE);
#endif
*_retval = PR_LoadLibrary(path.get());
#ifdef NS_BUILD_REFCNT_LOGGING
nsTraceRefcntImpl::SetActivityIsLegal(PR_TRUE);
#endif
NS_TIMELINE_STOP_TIMER("PR_LoadLibrary");
NS_TIMELINE_MARK_TIMER1("PR_LoadLibrary", path.get());