Bug 1476009: Remove unnecessary initialization. r=mak draft
authorRobert Bartlensky <rbartlensky@mozilla.com>
Mon, 16 Jul 2018 17:56:02 +0100
changeset 818835 11b65a89fdc9
parent 818682 2ed1506d1dc7
child 819240 69435087ddba
child 819241 39a435cacbbf
push id116365
push userbmo:rbartlensky@mozilla.com
push dateMon, 16 Jul 2018 16:57:28 +0000
reviewersmak
bugs1476009
milestone63.0a1
Bug 1476009: Remove unnecessary initialization. r=mak MozReview-Commit-ID: LyDzKB6gein
storage/mozStorageHelper.h
--- a/storage/mozStorageHelper.h
+++ b/storage/mozStorageHelper.h
@@ -149,17 +149,17 @@ public:
   nsresult Rollback()
   {
     if (!mConnection || mCompleted || !mHasTransaction)
       return NS_OK;
     mCompleted = true;
 
     // TODO (bug 1062823): from Sqlite 3.7.11 on, rollback won't ever return
     // a busy error, so this handling can be removed.
-    nsresult rv = NS_OK;
+    nsresult rv;
     do {
       rv = mConnection->ExecuteSimpleSQL(NS_LITERAL_CSTRING("ROLLBACK"));
       if (rv == NS_ERROR_STORAGE_BUSY)
         (void)PR_Sleep(PR_INTERVAL_NO_WAIT);
     } while (rv == NS_ERROR_STORAGE_BUSY);
 
     if (NS_SUCCEEDED(rv))
       mHasTransaction = false;