fix coverity issue 37/288737/1 accepted/tizen_unified tizen accepted/tizen/unified/20230316.174026
authorInki Dae <inki.dae@samsung.com>
Wed, 22 Feb 2023 07:29:02 +0000 (16:29 +0900)
committerInki Dae <inki.dae@samsung.com>
Wed, 22 Feb 2023 07:31:37 +0000 (16:31 +0900)
[Version] : 0.0.2
[Issue type] bug fix

CID : 1656258

Fixed a coverity issue, Dead default in switch.
For invalid format type, it will be handled by switch-case statement.
So drop unnecessary exception handling.

Change-Id: I6dee7f5e83682b4c05001317d3f3845980cfb728
Signed-off-by: Inki Dae <inki.dae@samsung.com>
packaging/inference-engine-armnn.spec
src/inference_engine_armnn.cpp

index 2a34d8dd9feb9c73567e6a5a7e12fb1f01746d58..70c12f7a5b98a29f951236d66ad0de2baaed29e8 100644 (file)
@@ -1,6 +1,6 @@
 Name:       inference-engine-armnn
 Summary:    ARM Neural Network Runtime based implementation of inference-engine-interface
-Version:    0.0.1
+Version:    0.0.2
 Release:    5
 Group:      Multimedia/Libraries
 License:    Apache-2.0
index 651ca928b34555575156944382bd636e397681ba..daf4b961b31c569e08ab35c97960c5070df55768 100644 (file)
@@ -214,15 +214,6 @@ namespace ARMNNImpl
        {
                LOGI("ENTER");
 
-               // Make sure to check if a given model format is supported or not.
-               if (model_format != INFERENCE_MODEL_CAFFE &&
-                       model_format != INFERENCE_MODEL_TF &&
-                       model_format != INFERENCE_MODEL_TFLITE &&
-                       model_format != INFERENCE_MODEL_ONNX) {
-                       LOGE("Invalid model format.");
-                       return INFERENCE_ENGINE_ERROR_NOT_SUPPORTED_FORMAT;
-               }
-
                int ret = INFERENCE_ENGINE_ERROR_NONE;
 
                switch ((int) model_format) {