Bug 1237679 - use sourceLocked to ensure users get warned to close the browser before running the migration, r=MattN
authorGijs Kruitbosch <gijskruitbosch@gmail.com>
Thu, 28 Jan 2016 16:35:04 +0000
changeset 328537 517bc7ebc8b1b748b3b3c85766b94a230d827f7a
parent 328536 7e8f5a46f8bae6e526ad83c81e135e9429d9fa72
child 328538 0d78a5256fb4432b256a5f94460db7f144db8a25
child 328566 3726ea673ea4a867fa8e0de39e14cc7a4e4ce019
child 328567 806034f2553ff7300dea4eb8645f5bb7bd324809
push id10368
push usergijskruitbosch@gmail.com
push dateWed, 03 Feb 2016 14:49:00 +0000
reviewersMattN
bugs1237679
milestone47.0a1
Bug 1237679 - use sourceLocked to ensure users get warned to close the browser before running the migration, r=MattN
browser/components/migration/EdgeProfileMigrator.js
--- a/browser/components/migration/EdgeProfileMigrator.js
+++ b/browser/components/migration/EdgeProfileMigrator.js
@@ -216,13 +216,19 @@ EdgeProfileMigrator.prototype.getResourc
  * - |[]| to indicate "There are no profiles" (on <=win8.1) which will avoid using this migrator.
  * See MigrationUtils.jsm for slightly more info on how sourceProfiles is used.
  */
 EdgeProfileMigrator.prototype.__defineGetter__("sourceProfiles", function() {
   let isWin10OrHigher = AppConstants.isPlatformAndVersionAtLeast("win", "10");
   return isWin10OrHigher ? null : [];
 });
 
+EdgeProfileMigrator.prototype.__defineGetter__("sourceLocked", function() {
+    // There is an exclusive lock on some databases. Assume they are locked for now.
+    return true;
+});
+
+
 EdgeProfileMigrator.prototype.classDescription = "Edge Profile Migrator";
 EdgeProfileMigrator.prototype.contractID = "@mozilla.org/profile/migrator;1?app=browser&type=edge";
 EdgeProfileMigrator.prototype.classID = Components.ID("{62e8834b-2d17-49f5-96ff-56344903a2ae}");
 
 this.NSGetFactory = XPCOMUtils.generateNSGetFactory([EdgeProfileMigrator]);