зеркало из https://github.com/mozilla/pjs.git
Make Linux and Mac installers install to the target directory instead of the
platform-specific notion of temp. [dogfood+ b=45166; r=dveditz]
This commit is contained in:
Родитель
76112996a5
Коммит
8fdf3f1c74
|
@ -543,10 +543,6 @@ nsSoftwareUpdate::StubInitialize(nsIFile *aDir, const char* logName)
|
|||
else if ( !aDir )
|
||||
return NS_ERROR_NULL_POINTER;
|
||||
|
||||
if (logName)
|
||||
mLogName = PL_strdup(logName);
|
||||
if (!mLogName)
|
||||
return NS_ERROR_OUT_OF_MEMORY;
|
||||
|
||||
// only allow once, it could be a mess if we've already started installing
|
||||
mStubLockout = PR_TRUE;
|
||||
|
@ -560,6 +556,14 @@ nsSoftwareUpdate::StubInitialize(nsIFile *aDir, const char* logName)
|
|||
if (NS_SUCCEEDED(rv))
|
||||
VR_SetRegDirectory( tempPath );
|
||||
|
||||
// Optionally set logfile leafname
|
||||
if (logName)
|
||||
{
|
||||
mLogName = PL_strdup(logName);
|
||||
if (!mLogName)
|
||||
return NS_ERROR_OUT_OF_MEMORY;
|
||||
}
|
||||
|
||||
// Create the logfile observer
|
||||
nsLoggingProgressListener *logger = new nsLoggingProgressListener();
|
||||
RegisterListener(logger);
|
||||
|
|
|
@ -200,7 +200,10 @@ PR_PUBLIC_API(nsresult) XPI_Init(
|
|||
#endif
|
||||
|
||||
if (hook && iDirSpec)
|
||||
hook->StubInitialize( iDirSpec, aLogName );
|
||||
{
|
||||
rv = hook->StubInitialize( iDirSpec, aLogName );
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
}
|
||||
else
|
||||
return NS_ERROR_NULL_POINTER;
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче