Changeset 94394 in vbox for trunk/src/VBox/Main
- Timestamp:
- Mar 29, 2022 3:50:26 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/src-server/MachineImpl.cpp
r94184 r94394 3544 3544 fSilent = true; 3545 3545 3546 /* Check that the controller can do hot plugging if we detach the device while the VM is running. */3546 /* Check that the controller can do hot-plugging if we attach the device while the VM is running. */ 3547 3547 bool fHotplug = false; 3548 3548 if (!fSilent && Global::IsOnlineOrTransient(mData->mMachineState)) … … 3551 3551 if (fHotplug && !i_isControllerHotplugCapable(ctrlType)) 3552 3552 return setError(VBOX_E_INVALID_VM_STATE, 3553 tr("Controller '%s' does not support hot plugging"),3553 tr("Controller '%s' does not support hot-plugging"), 3554 3554 aName.c_str()); 3555 3556 /* Attaching a USB device when a VM is powered off should default to being marked as hot-pluggable */ 3557 if (!fHotplug && !Global::IsOnlineOrTransient(mData->mMachineState) && ctrlType == StorageControllerType_USB) 3558 fHotplug = true; 3555 3559 3556 3560 // check that the port and device are not out of range … … 4122 4126 fSilent = true; 4123 4127 4124 /* Check that the controller can do hot plugging if we detach the device while the VM is running. */4128 /* Check that the controller can do hot-plugging if we detach the device while the VM is running. */ 4125 4129 bool fHotplug = false; 4126 4130 if (!fSilent && Global::IsOnlineOrTransient(mData->mMachineState)) … … 4129 4133 if (fHotplug && !i_isControllerHotplugCapable(ctrlType)) 4130 4134 return setError(VBOX_E_INVALID_VM_STATE, 4131 tr("Controller '%s' does not support hot plugging"),4135 tr("Controller '%s' does not support hot-plugging"), 4132 4136 aName.c_str()); 4133 4137 … … 4143 4147 if (fHotplug && !pAttach->i_getHotPluggable()) 4144 4148 return setError(VBOX_E_NOT_SUPPORTED, 4145 tr("The device slot %d on port %d of controller '%s' does not support hot plugging"),4149 tr("The device slot %d on port %d of controller '%s' does not support hot-plugging"), 4146 4150 aDevice, aControllerPort, aName.c_str()); 4147 4151 … … 4208 4212 fSilent = true; 4209 4213 4210 /* Check that the controller can do hot plugging if we detach the device while the VM is running. */4214 /* Check that the controller can do hot-plugging if we detach the device while the VM is running. */ 4211 4215 bool fHotplug = false; 4212 4216 if (!fSilent && Global::IsOnlineOrTransient(mData->mMachineState)) … … 4215 4219 if (fHotplug && !i_isControllerHotplugCapable(ctrlType)) 4216 4220 return setError(VBOX_E_INVALID_VM_STATE, 4217 tr("Controller '%s' does not support hot plugging which is required to change the passthrough setting while the VM is running"),4221 tr("Controller '%s' does not support hot-plugging which is required to change the passthrough setting while the VM is running"), 4218 4222 aName.c_str()); 4219 4223 … … 4413 4417 4414 4418 if (!i_isControllerHotplugCapable(ctrlType)) 4415 return setError(VBOX_E_NOT_SUPPORTED, 4416 tr("Controller '%s' does not support changing the hot-pluggable device flag"), 4417 aName.c_str()); 4419 return setError(VBOX_E_NOT_SUPPORTED, 4420 tr("Controller '%s' does not support changing the hot-pluggable device flag"), 4421 aName.c_str()); 4422 4423 /* silently ignore attempts to modify the hot-plug status of USB devices */ 4424 if (ctrlType == StorageControllerType_USB) 4425 return S_OK; 4418 4426 4419 4427 i_setModified(IsModified_Storage);
Note:
See TracChangeset
for help on using the changeset viewer.