VirtualBox

Changeset 38352 in vbox for trunk/src/VBox/Storage/testcase


Ignore:
Timestamp:
Aug 8, 2011 2:04:09 PM (13 years ago)
Author:
vboxsync
Message:

Storage/testcase: allow to create bigger virtual disk images than 1TB

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Storage/testcase/vditool.cpp

    r36344 r38352  
    9292}
    9393
    94 static int NewImage(const char *pszFilename, uint32_t cMBs)
    95 {
    96     RTPrintf("Creating VDI: file=\"%s\" size=%u MB...\n",
     94static int NewImage(const char *pszFilename, uint64_t cMBs)
     95{
     96    RTPrintf("Creating VDI: file=\"%s\" size=%RU64MB...\n",
    9797            pszFilename, cMBs);
    9898
     
    408408            return SyntaxError("Invalid argument count!");
    409409
    410         uint32_t cMBs;
    411         rc = RTStrToUInt32Ex(argv[3], NULL, 10, &cMBs);
     410        uint64_t cMBs;
     411        rc = RTStrToUInt64Ex(argv[3], NULL, 10, &cMBs);
    412412        if (RT_FAILURE(rc))
    413413            return SyntaxError("Invalid number!");
    414         if (cMBs < 2 || cMBs > _1M)
     414        if (cMBs < 2)
    415415        {
    416             RTPrintf("error: Disk size %RU32 (MB) is not within the range %u-%u!\n",
    417                      cMBs, 2, _1M);
     416            RTPrintf("error: Disk size %RU64MB must be at least 2MB!\n", cMBs);
    418417            return 1;
    419418        }
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