mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2026-06-08 01:54:44 +00:00
HV: Assignment should not mix with operator
Removed the postfix and prefix operation in assignment expression. Noncompliant code example: 1) *a++ = *b ++; 2) a = arr[--b]; Signed-off-by: Yang, Yu-chu <yu-chu.yang@intel.com>
This commit is contained in:
@@ -68,7 +68,8 @@ static inline int set_vcpuid_entry(struct vm *vm,
|
||||
return -ENOMEM;
|
||||
}
|
||||
|
||||
tmp = &vm->vcpuid_entries[vm->vcpuid_entry_nr++];
|
||||
tmp = &vm->vcpuid_entries[vm->vcpuid_entry_nr];
|
||||
vm->vcpuid_entry_nr++;
|
||||
(void)memcpy_s(tmp, entry_size, entry, entry_size);
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user