Repository navigation
Commit 871c433
KVM: use struct_size() and flex_array_size() helpers in kvm_io_bus_unregister_dev()
Make use of the struct_size() helper to avoid any potential type
mistakes and protect against potential integer overflows
Make use of the flex_array_size() helper to calculate the size of a
flexible array member within an enclosing structure
Suggested-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Signed-off-by: Rustam Kovhaev <rkovhaev@gmail.com>
Message-Id: <20200918120500.954436-1-rkovhaev@gmail.com>
Reviewed-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>1 parent 4407a79 commit 871c433
1 file changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4350 | 4350 | | |
4351 | 4351 | | |
4352 | 4352 | | |
4353 | | - | |
| 4353 | + | |
4354 | 4354 | | |
4355 | 4355 | | |
4356 | | - | |
| 4356 | + | |
4357 | 4357 | | |
4358 | 4358 | | |
4359 | 4359 | | |
| |||
0 commit comments