[tracker/wip/carlosg/coverity-warnings: 14/27] libtracker-data: Free variable using the right free function
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/wip/carlosg/coverity-warnings: 14/27] libtracker-data: Free variable using the right free function
- Date: Fri, 26 Mar 2021 11:22:24 +0000 (UTC)
commit 954ca422d3d6c5150349d8350a08aaff1678c084
Author: Carlos Garnacho <carlosg gnome org>
Date: Sat Mar 20 11:30:45 2021 +0100
libtracker-data: Free variable using the right free function
This variable is allocated with sqlite3_malloc, should be freed with
sqlite3_free().
CID: #1501147
src/libtracker-data/tracker-vtab-triples.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/libtracker-data/tracker-vtab-triples.c b/src/libtracker-data/tracker-vtab-triples.c
index a81709cd0..081566ae0 100644
--- a/src/libtracker-data/tracker-vtab-triples.c
+++ b/src/libtracker-data/tracker-vtab-triples.c
@@ -192,7 +192,7 @@ triples_best_index (sqlite3_vtab *vtab,
continue;
if (info->aConstraint[i].iColumn == COL_ROWID) {
- g_free (idx_str);
+ sqlite3_free (idx_str);
return SQLITE_ERROR;
}
@@ -201,7 +201,7 @@ triples_best_index (sqlite3_vtab *vtab,
info->aConstraint[i].op != SQLITE_INDEX_CONSTRAINT_NE &&
info->aConstraint[i].op != SQLITE_INDEX_CONSTRAINT_ISNULL &&
info->aConstraint[i].op != SQLITE_INDEX_CONSTRAINT_ISNOTNULL) {
- g_free (idx_str);
+ sqlite3_free (idx_str);
return SQLITE_ERROR;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]