VirtualBox

Changeset 76732 in vbox for trunk/src/VBox/Additions


Ignore:
Timestamp:
Jan 9, 2019 11:32:40 AM (6 years ago)
Author:
vboxsync
Message:

VBoxGuest/os2: Do some command line parsing. ticketref:16871

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/common/VBoxGuest/VBoxGuest-os2.cpp

    r76553 r76732  
    145145    {
    146146        /*
    147          * Process the commandline. Later.
     147         * Process the command line.
    148148         */
    149149        bool fVerbose = true;
     150        if (pszArgs)
     151        {
     152            char ch;
     153            while ((ch = *pszArgs++) != '\0')
     154                if (ch == '-' || ch == '/')
     155                {
     156                    ch = *pszArgs++;
     157                    if (ch == 'Q' || ch == 'q')
     158                        fVerbose = false;
     159                    else if (ch == 'V' || ch == 'v')
     160                        fVerbose = true;
     161                    else if (ch == '\0')
     162                        break;
     163                    /*else: ignore stuff we don't know what is */
     164                }
     165                /* else: skip spaces and unknown stuff */
     166        }
    150167
    151168        /*
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