SWDEV-313213 - hipGraphDestroy issues

Change-Id: Idf3ede5ea29161b9e5753e8beb245b1f9fd86d28


[ROCm/clr commit: 42137222ad]
This commit is contained in:
Ajay committed 2022-03-10 19:54:01 +00:00
1 parent eba59236b1
commit f365706d25
1 file changed
+4
+4
View File
@@ -824,6 +824,10 @@ hipError_t hipGraphDestroy(hipGraph_t graph) {
if (graph == nullptr) {
HIP_RETURN(hipErrorInvalidValue);
}
// if graph is not valid its destroyed already
if (!ihipGraph::isGraphValid(graph)) {
HIP_RETURN(hipErrorInvalidValue);
}
delete graph;
HIP_RETURN(hipSuccess);
}