зеркало из https://github.com/mozilla/pjs.git
Bug 337002: NS_ERROR_FILE_NOT_FOUND error is dumped to console sometimes from sss_clearDisk, patch by logan <mozilla@gozer.org>, r=dietrich
This commit is contained in:
Родитель
1758a163ed
Коммит
8aad2f8087
|
@ -1672,14 +1672,22 @@ SessionStoreService.prototype = {
|
|||
* delete session datafile and backup
|
||||
*/
|
||||
_clearDisk: function sss_clearDisk() {
|
||||
try {
|
||||
this._getSessionFile().remove(false);
|
||||
var file = this._getSessionFile();
|
||||
|
||||
if (file.exists()) {
|
||||
try {
|
||||
file.remove(false);
|
||||
}
|
||||
catch (ex) { dump(ex + '\n'); } // couldn't remove the file - what now?
|
||||
}
|
||||
catch (ex) { dump(ex); } // couldn't remove the file - what now?
|
||||
|
||||
if (!this._lastSessionCrashed)
|
||||
return;
|
||||
|
||||
try {
|
||||
this._getSessionFile(true).remove(false);
|
||||
}
|
||||
catch (ex) { dump(ex); } // couldn't remove the file - what now?
|
||||
catch (ex) { dump(ex + '\n'); } // couldn't remove the file - what now?
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
Загрузка…
Ссылка в новой задаче