From 5ed5f13920b66098cf3bfe7da85f463e6ff64bac Mon Sep 17 00:00:00 2001 From: Kaz Nishimura Date: Fri, 15 Sep 2023 09:47:45 +0900 Subject: [PATCH] [DML EP] Add missing member initializer DmlGraphNodeCreateInfo::nodeCount (#17505) ### Description This adds a missing member initialization. ### Motivation and Context It caused an access violation in `Dml::GraphDescBuilder::BuildGraphDesc`. --- .../dml/DmlExecutionProvider/inc/IWinmlExecutionProvider.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/onnxruntime/core/providers/dml/DmlExecutionProvider/inc/IWinmlExecutionProvider.h b/onnxruntime/core/providers/dml/DmlExecutionProvider/inc/IWinmlExecutionProvider.h index 232a022d869f4..04381b6ce355c 100644 --- a/onnxruntime/core/providers/dml/DmlExecutionProvider/inc/IWinmlExecutionProvider.h +++ b/onnxruntime/core/providers/dml/DmlExecutionProvider/inc/IWinmlExecutionProvider.h @@ -80,7 +80,7 @@ namespace Windows::AI::MachineLearning::Adapter // Either nodesAsOperatorDesc or nodesAsIDMLOperator can have non-zero size. struct DmlGraphNodeCreateInfo { - uint32_t nodeCount; + uint32_t nodeCount = 0; std::vector> nodesAsOperatorDesc; std::vector> nodesAsIDMLOperator; std::vector inputEdges;