зеркало из https://github.com/mozilla/pjs.git
Commenting out additional stat on bookmarks file to measure startup perf impact.
This commit is contained in:
Родитель
7038613018
Коммит
7abbce1870
|
@ -1712,8 +1712,9 @@ static BookmarkManager* gBookmarkManager = nil;
|
||||||
BOOL success = [dict writeToFile:backupFile atomically:YES];
|
BOOL success = [dict writeToFile:backupFile atomically:YES];
|
||||||
if (success)
|
if (success)
|
||||||
{
|
{
|
||||||
long long bmFileSize = [[NSFileManager defaultManager] sizeOfFileAtPath:backupFile traverseLink:YES];
|
// XXX removed to measure hit on startup perf
|
||||||
if (bmFileSize > 0)
|
// long long bmFileSize = [[NSFileManager defaultManager] sizeOfFileAtPath:backupFile traverseLink:YES];
|
||||||
|
// if (bmFileSize > 0)
|
||||||
{
|
{
|
||||||
NSFileManager* fm = [NSFileManager defaultManager];
|
NSFileManager* fm = [NSFileManager defaultManager];
|
||||||
BOOL removedOld = [fm removeFileAtPath:stdPath handler:self]; // out with the old...
|
BOOL removedOld = [fm removeFileAtPath:stdPath handler:self]; // out with the old...
|
||||||
|
@ -1723,8 +1724,8 @@ static BookmarkManager* gBookmarkManager = nil;
|
||||||
stdPath, removedOld,
|
stdPath, removedOld,
|
||||||
backupFile, movedNew);
|
backupFile, movedNew);
|
||||||
}
|
}
|
||||||
else
|
// else
|
||||||
NSLog(@"writePropertyList: saved bookmarks file was empty (%qi bytes))", bmFileSize);
|
// NSLog(@"writePropertyList: saved bookmarks file was empty (%qi bytes))", bmFileSize);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
NSLog(@"writePropertyList: Failed to write file %@", pathToFile);
|
NSLog(@"writePropertyList: Failed to write file %@", pathToFile);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче