Skip to content

Commit

Permalink
Check if properties param is null in L0 urMemBufferCreateWithNativeHa…
Browse files Browse the repository at this point in the history
…ndle and set OwnNativeHandle to false by default.
  • Loading branch information
martygrant committed Nov 6, 2024
1 parent d39870b commit 65edd6b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion source/adapters/level_zero/memory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1746,7 +1746,7 @@ ur_result_t urMemBufferCreateWithNativeHandle(
ur_mem_handle_t
*Mem ///< [out] pointer to handle of buffer memory object created.
) {
bool OwnNativeHandle = Properties->isNativeHandleOwned;
bool OwnNativeHandle = Properties ? Properties->isNativeHandleOwned : false;

std::shared_lock<ur_shared_mutex> Lock(Context->Mutex);

Expand Down

0 comments on commit 65edd6b

Please sign in to comment.