ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [18/21] ignite git commit: IGNITE-5753: CPP Memory leak fixed.
Date Mon, 17 Jul 2017 08:22:55 GMT
IGNITE-5753: CPP Memory leak fixed.


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/07cc05f5
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/07cc05f5
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/07cc05f5

Branch: refs/heads/ignite-5578-locJoin
Commit: 07cc05f51666b19598abf0e8dcb2d2e534369df3
Parents: 038a90a
Author: Igor Sapego <isapego@gridgain.com>
Authored: Fri Jul 14 18:23:46 2017 +0300
Committer: Igor Sapego <isapego@gridgain.com>
Committed: Fri Jul 14 18:23:46 2017 +0300

----------------------------------------------------------------------
 .../platforms/cpp/core/include/ignite/cache/query/query_sql.h    | 4 ++++
 .../cpp/core/include/ignite/cache/query/query_sql_fields.h       | 4 ++++
 2 files changed, 8 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/07cc05f5/modules/platforms/cpp/core/include/ignite/cache/query/query_sql.h
----------------------------------------------------------------------
diff --git a/modules/platforms/cpp/core/include/ignite/cache/query/query_sql.h b/modules/platforms/cpp/core/include/ignite/cache/query/query_sql.h
index eb0606a..365dcaa 100644
--- a/modules/platforms/cpp/core/include/ignite/cache/query/query_sql.h
+++ b/modules/platforms/cpp/core/include/ignite/cache/query/query_sql.h
@@ -249,6 +249,10 @@ namespace ignite
                  */
                 void ClearArguments()
                 {
+                    std::vector<impl::cache::query::QueryArgumentBase*>::iterator iter;
+                    for (iter = args.begin(); iter != args.end(); ++iter)
+                        delete *iter;
+
                     args.clear();
                 }
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/07cc05f5/modules/platforms/cpp/core/include/ignite/cache/query/query_sql_fields.h
----------------------------------------------------------------------
diff --git a/modules/platforms/cpp/core/include/ignite/cache/query/query_sql_fields.h b/modules/platforms/cpp/core/include/ignite/cache/query/query_sql_fields.h
index bf8d7ac..e00da28 100644
--- a/modules/platforms/cpp/core/include/ignite/cache/query/query_sql_fields.h
+++ b/modules/platforms/cpp/core/include/ignite/cache/query/query_sql_fields.h
@@ -278,6 +278,10 @@ namespace ignite
                  */
                 void ClearArguments()
                 {
+                    std::vector<impl::cache::query::QueryArgumentBase*>::iterator iter;
+                    for (iter = args.begin(); iter != args.end(); ++iter)
+                        delete *iter;
+
                     args.clear();
                 }
 


Mime
View raw message