Index: /trunk/src/VBox/Main/MachineImpl.cpp
===================================================================
--- /trunk/src/VBox/Main/MachineImpl.cpp	(revision 22624)
+++ /trunk/src/VBox/Main/MachineImpl.cpp	(revision 22625)
@@ -6176,4 +6176,16 @@
                                               &aProgress);
 
+            // at this point, the old image is still locked for writing, but instead
+            // we need the new diff image locked for writing and lock the previously
+            // current one for reading only
+            if (aOnline)
+            {
+                diff->LockWrite(NULL);
+                mData->mSession.mLockedMedia.push_back(Data::Session::LockedMedia::value_type(ComPtr<IHardDisk>(diff), true));
+                hd->UnlockWrite(NULL);
+                hd->LockRead(NULL);
+                mData->mSession.mLockedMedia.push_back(Data::Session::LockedMedia::value_type(ComPtr<IHardDisk>(hd), false));
+            }
+
             alock.enter();
 
