Changeset 1259 in vbox
- Timestamp:
- Mar 6, 2007 11:16:33 AM (18 years ago)
- svn:sync-xref-src-repo-rev:
- 19204
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxManage/VBoxManage.cpp
r1061 r1259 254 254 { 255 255 RTPrintf("VBoxManage showvminfo <uuid>|<name>\n" 256 " [-details]\n" 256 257 "\n"); 257 258 } … … 652 653 653 654 static HRESULT showVMInfo (ComPtr <IVirtualBox> virtualBox, ComPtr<IMachine> machine, 654 ComPtr <IConsole> console = ComPtr <IConsole> ()) 655 ComPtr <IConsole> console = ComPtr <IConsole> (), 656 bool fDetails = false) 655 657 { 656 658 HRESULT rc; … … 1399 1401 } 1400 1402 1403 if (fDetails) 1404 { 1405 Bstr description; 1406 machine->COMGETTER(Description)(description.asOutParam()); 1407 if (!description.isEmpty()) 1408 { 1409 RTPrintf("Description:\n%lS\n", description.raw()); 1410 } 1411 } 1412 1401 1413 /* 1402 1414 * snapshots … … 1419 1431 HRESULT rc; 1420 1432 1421 /* exactlyone option: the UUID or name of the VM */1422 if (argc !=1)1433 /* at least one option: the UUID or name of the VM */ 1434 if (argc < 1) 1423 1435 { 1424 1436 return errorSyntax(USAGE_SHOWVMINFO, "Incorrect number of parameters"); … … 1440 1452 if (FAILED (rc)) 1441 1453 return 1; 1454 1455 /* 2nd option can be -details */ 1456 bool fDetails = false; 1457 if ((argc == 2) && !strcmp(argv[1], "-details")) 1458 fDetails = true; 1442 1459 1443 1460 ComPtr <IConsole> console; … … 1452 1469 rc = session->COMGETTER(Console)(console.asOutParam()); 1453 1470 1454 rc = showVMInfo (virtualBox, machine, console );1471 rc = showVMInfo (virtualBox, machine, console, fDetails); 1455 1472 1456 1473 if (console)
Note:
See TracChangeset
for help on using the changeset viewer.