VirtualBox

Ignore:
Timestamp:
Nov 2, 2009 1:30:13 PM (15 years ago)
Author:
vboxsync
Message:

Frontend/VirtualBox: drop non-working synonyms for --startvm, and document the consistency requirement across three files

Location:
trunk/src/VBox/Frontends/VirtualBox/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/VBoxGlobal.cpp

    r24152 r24252  
    46684668    {
    46694669        const char *arg = qApp->argv() [i];
    4670         if (    !::strcmp (arg, "--startvm")
    4671             ||  !::strcmp (arg, "-startvm")
    4672             ||  !::strcmp (arg, "-s")
    4673             ||  !::strcmp (arg, "--vm")
    4674             ||  !::strcmp (arg, "-vm"))
     4670        /* NOTE: the check here must match the corresponding check for the
     4671         * options to start a VM in main.cpp and hardenedmain.cpp exactly,
     4672         * otherwise there will be weird error messages. */
     4673        if (   !::strcmp (arg, "--startvm")
     4674            || !::strcmp (arg, "-startvm"))
    46754675        {
    46764676            if (++i < argc)
  • trunk/src/VBox/Frontends/VirtualBox/src/hardenedmain.cpp

    r18789 r24252  
    3131    uint32_t fFlags = SUPSECMAIN_FLAGS_DONT_OPEN_DEV;
    3232    for (int i = 1; i < argc; i++)
    33         if (    !strcmp(argv[i], "--startvm")
    34             ||  !strcmp(argv[i], "-startvm"))
     33        /* NOTE: the check here must match the corresponding check for the
     34         * options to start a VM in main.cpp and VBoxGlobal.cpp exactly,
     35         * otherwise there will be weird error messages. */
     36        if (   !::strcmp(argv[i], "--startvm")
     37            || !::strcmp(argv[i], "-startvm"))
    3538        {
    3639            fFlags &= ~SUPSECMAIN_FLAGS_DONT_OPEN_DEV;
  • trunk/src/VBox/Frontends/VirtualBox/src/main.cpp

    r23948 r24252  
    568568    for (int i = 1; i < argc; i++)
    569569    {
    570         if (    !::strcmp(argv[i], "--startvm")
    571             ||  !::strcmp(argv[i], "-startvm"))
     570        /* NOTE: the check here must match the corresponding check for the
     571         * options to start a VM in hardenedmain.cpp and VBoxGlobal.cpp exactly,
     572         * otherwise there will be weird error messages. */
     573        if (   !::strcmp(argv[i], "--startvm")
     574            || !::strcmp(argv[i], "-startvm"))
    572575        {
    573576            fInitSUPLib = true;
Note: See TracChangeset for help on using the changeset viewer.

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