VirtualBox

Changeset 24136 in vbox for trunk/src/VBox/Main/xml


Ignore:
Timestamp:
Oct 28, 2009 12:48:41 PM (16 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
54055
Message:

Main,VBoxManage,xml: Added a HardwareUUID property for reporting the original machine UUID after cloning or teleporting a VM.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/xml/Settings.cpp

    r23808 r24136  
    14471447            // defaults to 2 and is only written if != 2
    14481448
     1449    Utf8Str strUUID;
     1450    if (elmHardware.getAttributeValue("uuid", strUUID))
     1451        parseUUID(hw.uuid, strUUID);
     1452    else
     1453        hw.uuid.clear();
     1454
    14491455    xml::NodesLoop nl1(elmHardware);
    14501456    const xml::ElementNode *pelmHwChild;
     
    23302336    if (hw.strVersion != "2")
    23312337        pelmHardware->setAttribute("version", hw.strVersion);
     2338    if (!hw.uuid.isEmpty())
     2339        pelmHardware->setAttribute("uuid", makeString(hw.uuid));
    23322340
    23332341    xml::ElementNode *pelmCPU      = pelmHardware->createChild("CPU");
     
    28962904            )
    28972905       )
     2906        m->sv = SettingsVersion_v1_9;
     2907
     2908    if (    m->sv < SettingsVersion_v1_9
     2909        &&  !hardwareMachine.uuid.isEmpty())
    28982910        m->sv = SettingsVersion_v1_9;
    28992911}
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette