Skip to content

Commit 6090c32

Browse files
committed
Remove return of stream to manager to avoid double free
1 parent 1fea0fb commit 6090c32

File tree

1 file changed

+2
-6
lines changed
  • offload/plugins-nextgen/cuda/src

1 file changed

+2
-6
lines changed

offload/plugins-nextgen/cuda/src/rtl.cpp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -954,14 +954,10 @@ struct CUDADeviceTy : public GenericDeviceTy {
954954
if (!Interop)
955955
return Plugin::success();
956956

957-
if (Interop->async_info) {
958-
if (auto Err = CUDAStreamManager.returnResource(
959-
*static_cast<CUstream *>(Interop->async_info->Queue)))
960-
return Err;
957+
if (Interop->async_info)
961958
delete Interop->async_info;
962-
}
963-
delete Interop;
964959

960+
delete Interop;
965961
return Plugin::success();
966962
}
967963

0 commit comments

Comments
 (0)