aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorTeresa Charlin <teresa.charlinreyes@arm.com>2023-04-20 11:55:48 +0100
committerTeresaARM <teresa.charlinreyes@arm.com>2023-04-20 11:07:12 +0000
commit4cf40d70f8e9da3184bb4c9b604db6a3b23d6533 (patch)
tree12fb7e39bf0c9d093b5660962cad8e583eb130b3 /include
parentd328959f28b857fd2b4594f587d5a30f02f6c029 (diff)
downloadarmnn-4cf40d70f8e9da3184bb4c9b604db6a3b23d6533.tar.gz
GitHub #723 Fix Maybe uninitialized variable
Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: I70d3673bbb2dc113ac5eb6d63029a4a4a684e831
Diffstat (limited to 'include')
-rw-r--r--include/armnn/backends/Workload.hpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/armnn/backends/Workload.hpp b/include/armnn/backends/Workload.hpp
index be6fbd977f..9f7aad0b55 100644
--- a/include/armnn/backends/Workload.hpp
+++ b/include/armnn/backends/Workload.hpp
@@ -1,5 +1,5 @@
//
-// Copyright © 2022 Arm Ltd and Contributors. All rights reserved.
+// Copyright © 2022-2023 Arm Ltd and Contributors. All rights reserved.
// SPDX-License-Identifier: MIT
//
#pragma once
@@ -124,6 +124,8 @@ public:
if (!info.m_InputTensorInfos.empty())
{
+ expectedInputType = info.m_InputTensorInfos.front().GetDataType();
+
if (expectedOutputType != expectedInputType)
{
ARMNN_ASSERT_MSG(false, "Trying to create workload with incorrect type");