SWDEV-325545 - hipGraphGetEdges when both from/to are null
Change-Id: Id69d87537a8a7fb7df447cee586137ff1342ce26
This commit is contained in:
@@ -1292,7 +1292,8 @@ hipError_t hipGraphGetEdges(hipGraph_t graph, hipGraphNode_t* from, hipGraphNode
|
||||
size_t* numEdges) {
|
||||
HIP_INIT_API(hipGraphGetEdges, graph, from, to, numEdges);
|
||||
if (graph == nullptr || numEdges == nullptr ||
|
||||
from == nullptr || to == nullptr) {
|
||||
(from == nullptr && to != nullptr) ||
|
||||
(to == nullptr && from != nullptr)) {
|
||||
HIP_RETURN(hipErrorInvalidValue);
|
||||
}
|
||||
const std::vector<std::pair<Node, Node>> edges = graph->GetEdges();
|
||||
|
||||
Reference in New Issue
Block a user