vishesh92 commented on code in PR #8624: URL: https://github.com/apache/cloudstack/pull/8624#discussion_r1595216992
########## server/src/main/java/com/cloud/vm/UserVmManagerImpl.java: ########## @@ -1566,7 +1566,7 @@ public UserVm removeNicFromVirtualMachine(RemoveNicFromVMCmd cmd) throws Invalid } // check to see if nic is attached to VM - if (nic.getInstanceId() != vmId) { + if (!nic.getInstanceId().equals(vmId)) { Review Comment: Is it possible for `nic.getInstanceId()` to be `null`? If it can be `null`, this will throw an NPE. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@cloudstack.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org