Fix "Unable to override non-custom VMware adapter".

This commit is contained in:
grossmj 2018-02-04 22:08:41 +08:00
parent 654aa18d09
commit 52b690b683

View File

@ -745,7 +745,7 @@ class VMwareVM(BaseNode):
"Please remove it or allow VMware VM '{name}' to use any adapter.".format(attachment=self._vmx_pairs[connection_type], "Please remove it or allow VMware VM '{name}' to use any adapter.".format(attachment=self._vmx_pairs[connection_type],
adapter_number=adapter_number, adapter_number=adapter_number,
name=self.name)) name=self.name))
elif self.is_running(): elif (yield from self.is_running()):
raise VMwareError("Attachment '{attachment}' is configured on network adapter {adapter_number}. " raise VMwareError("Attachment '{attachment}' is configured on network adapter {adapter_number}. "
"Please stop VMware VM '{name}' to link to this adapter and allow GNS3 to change the attachment type.".format(attachment=self._vmx_pairs[connection_type], "Please stop VMware VM '{name}' to link to this adapter and allow GNS3 to change the attachment type.".format(attachment=self._vmx_pairs[connection_type],
adapter_number=adapter_number, adapter_number=adapter_number,