Tests/AppTests: Fix an SVACE warning 98343
authorWook Song <wook16.song@samsung.com>
Wed, 26 Mar 2025 04:19:47 +0000 (13:19 +0900)
committerWook Song <wook16.song@samsung.com>
Wed, 26 Mar 2025 10:41:59 +0000 (19:41 +0900)
This patch resolves an SVACE warning 98434, which is reported by the
INVARIANT_RESULT.OP_ZERO checker.

Change-Id: If2980971cb31a2871e1d8f856c522769708b4315
Signed-off-by: Wook Song <wook16.song@samsung.com>
tests/apptests/tvn_triv2_xml.cc

index 48d1195389ec48693da0286bd2d851b400090946..064c083b2ded279b8f367e73c3735e587ba8ad6c 100644 (file)
@@ -68,8 +68,8 @@ class Tester : public UtilTRIV2 {
 
     XMLElement *elem = root->FirstChildElement ("model");
     while (elem != nullptr) {
-      int priority = elem->IntAttribute ("priority");
-      int timeout = elem->IntAttribute ("timeout");
+      int priority = elem->IntAttribute ("priority", -1);
+      int timeout = elem->IntAttribute ("timeout", -1);
 
       if (priority < NPU_PRIORITY_LOW || priority > NPU_PRIORITY_HIGH || timeout < 0)
         return -EINVAL;