Skip to content

Commit 50a7afe

Browse files
committed
Assert that Device is valid for memory poisoning
This (hopefully) silences a Coverity issue.
1 parent 2a38201 commit 50a7afe

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

source/loader/layers/sanitizer/msan/msan_interceptor.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ ur_result_t MsanInterceptor::allocateMemory(ur_context_handle_t Context,
7575
if (Type != AllocType::DEVICE_USM) {
7676
return UR_RESULT_SUCCESS;
7777
}
78+
assert(Device);
7879

7980
auto AI = std::make_shared<MsanAllocInfo>(MsanAllocInfo{(uptr)Allocated,
8081
Size,

0 commit comments

Comments
 (0)