aboutsummaryrefslogtreecommitdiff
path: root/delegate/classic/src/ClassicDelegateUtils.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'delegate/classic/src/ClassicDelegateUtils.hpp')
-rw-r--r--delegate/classic/src/ClassicDelegateUtils.hpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/delegate/classic/src/ClassicDelegateUtils.hpp b/delegate/classic/src/ClassicDelegateUtils.hpp
index 8a9409df6a..8d6f0495f8 100644
--- a/delegate/classic/src/ClassicDelegateUtils.hpp
+++ b/delegate/classic/src/ClassicDelegateUtils.hpp
@@ -193,7 +193,10 @@ TfLiteStatus Connect(armnn::IConnectableLayer* layer,
TfLiteNode* tfLiteNode,
armnnDelegate::DelegateData& data)
{
- ARMNN_ASSERT(static_cast<unsigned int>(tfLiteNode->outputs->size) == layer->GetNumOutputSlots());
+ if (static_cast<unsigned int>(tfLiteNode->outputs->size) != layer->GetNumOutputSlots())
+ {
+ return kTfLiteError;
+ }
// Connect the input slots
for (unsigned int inputIndex = 0; inputIndex < layer->GetNumInputSlots(); ++inputIndex)