Changeset 23935 in vbox
- Timestamp:
- Oct 21, 2009 2:18:11 PM (15 years ago)
- svn:sync-xref-src-repo-rev:
- 53747
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxManage/VBoxManage.cpp
r23934 r23935 572 572 /* try to find the given machine */ 573 573 ComPtr <IMachine> machine; 574 Bstr uuid (a->argv[0]);575 if (!Guid( uuid).isEmpty())576 { 577 CHECK_ERROR(a->virtualBox, GetMachine( uuid, machine.asOutParam()));574 Bstr machineuuid (a->argv[0]); 575 if (!Guid(machineuuid).isEmpty()) 576 { 577 CHECK_ERROR(a->virtualBox, GetMachine(machineuuid, machine.asOutParam())); 578 578 } 579 579 else 580 580 { 581 CHECK_ERROR(a->virtualBox, FindMachine( uuid, machine.asOutParam()));581 CHECK_ERROR(a->virtualBox, FindMachine(machineuuid, machine.asOutParam())); 582 582 if (SUCCEEDED (rc)) 583 machine->COMGETTER(Id)( uuid.asOutParam());583 machine->COMGETTER(Id)(machineuuid.asOutParam()); 584 584 } 585 585 if (FAILED (rc)) … … 587 587 588 588 /* open a session for the VM */ 589 CHECK_ERROR_RET(a->virtualBox, OpenExistingSession(a->session, uuid), 1);589 CHECK_ERROR_RET(a->virtualBox, OpenExistingSession(a->session, machineuuid), 1); 590 590 591 591 do … … 1121 1121 else if (!strcmp(a->argv[1], "dvdattach")) 1122 1122 { 1123 Bstr uuid; 1123 1124 if (a->argc != 3) 1124 1125 { … … 1153 1154 { 1154 1155 /* first assume it's a UUID */ 1155 Bstr uuid(a->argv[2]);1156 uuid = a->argv[2]; 1156 1157 rc = a->virtualBox->GetDVDImage(uuid, dvdMedium.asOutParam()); 1157 1158 if (FAILED(rc) || !dvdMedium) … … 1184 1185 else if (!strcmp(a->argv[1], "floppyattach")) 1185 1186 { 1187 Bstr uuid; 1186 1188 if (a->argc != 3) 1187 1189 { … … 1215 1217 { 1216 1218 /* first assume it's a UUID */ 1217 Bstr uuid(a->argv[2]);1219 uuid = a->argv[2]; 1218 1220 rc = a->virtualBox->GetFloppyImage(uuid, floppyMedium.asOutParam()); 1219 1221 if (FAILED(rc) || !floppyMedium)
Note:
See TracChangeset
for help on using the changeset viewer.