Fixed coverity issues in src/acl_kernel.cpp #221
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixed coverity issue in acl_kernel.cpp: Type: Invalid type in argument to printf format specifier (PRINTF_ARGS)
local_work_size[idim]
is of typesize_t
therefore using%zu
instead of%d
.Fixed coverity issue in acl_kernel.cpp: Type: Uninitialized scalar variable (UNINIT)
Function
l_copy_and_adjust_arguments_for_device
atline 2164
usesmemory_migration.num_mem_objects
, butmemory_migration
has only been declared up until this point. I assume that since there has been no changes tomemory_migration
, upon declaration, thenum_mem_objects
should be set to 0. This assumption is reinforced by the second occurrence ofl_copy_and_adjust_arguments_for_device
atline 2228
wherememory_migration.num_mem_objects = 0
is been initialized a few lines before.