VirtualBox

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


Ignore:
Timestamp:
May 31, 2013 8:25:22 PM (12 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
86144
Message:

The ICON data isn't required, it's optional so dont fail in copyMachineDataToSettings because of this. For the same reason, don't save the <Icon> element unconditionally, only when there is actual data. Because, we have to bump the settings version when using <Icon>.

File:
1 edited

Legend:

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

    r46348 r46351  
    48494849    if (machineUserData.strDescription.length())
    48504850        elmMachine.createChild("Description")->addContent(machineUserData.strDescription);
    4851     elmMachine.setAttribute("Icon", machineUserData.ovIcon);
     4851    if (machineUserData.ovIcon.length())
     4852        elmMachine.setAttribute("Icon", machineUserData.ovIcon);
    48524853    elmMachine.setAttribute("OSType", machineUserData.strOsType);
    48534854    if (    strStateFile.length()
     
    50515052        if (   !hardwareMachine.strDefaultFrontend.isEmpty()
    50525053            || hardwareMachine.graphicsControllerType != GraphicsControllerType_VBoxVGA
    5053             || hardwareMachine.enmLongMode != Hardware::LongMode_Legacy)
     5054            || hardwareMachine.enmLongMode != Hardware::LongMode_Legacy
     5055            || machineUserData.ovIcon.length() > 0)
    50545056            m->sv = SettingsVersion_v1_14;
    50555057    }
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