AccessibleNode: resolve possible memory leak
authorJongmin Lee <jm105.lee@samsung.com>
Tue, 9 Jun 2020 06:37:11 +0000 (15:37 +0900)
committerJongmin Lee <jm105.lee@samsung.com>
Thu, 11 Jun 2020 22:02:32 +0000 (07:02 +0900)
Change-Id: Ic3489d65ba042a01674c32d7534caed5fb66281e

libaurum/src/AccessibleNode.cc

index 3d46332..3ec0d33 100644 (file)
@@ -70,7 +70,11 @@ AccessibleNode::AccessibleNode(AtspiAccessible *node)
                     static_cast<int>(AccessibleNodeInterface::TABLECELL);
             else
                 LOG_F(WARNING, "Not Supported interface found %s", iface);
+
+            g_free(iface);
         }
+
+        g_array_free(ifaces, FALSE);
     }
     this->refresh();
 }
@@ -117,6 +121,7 @@ void AccessibleNode::refresh() const
     }
 
     if (states) g_array_free(states, 0);
+    g_object_unref(st);
 }
 
 int AccessibleNode::getChildCount() const