[tracker/wip/carlosg/libtracker-data-fixes: 3/3] libtracker-data: Flush buffer before resolving INSERT/DELETE/WHERE solution
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/wip/carlosg/libtracker-data-fixes: 3/3] libtracker-data: Flush buffer before resolving INSERT/DELETE/WHERE solution
- Date: Thu, 23 Dec 2021 23:09:36 +0000 (UTC)
commit 26b3633e95cb5a601cd42a5689820605b6378bc2
Author: Carlos Garnacho <carlosg gnome org>
Date: Thu Dec 23 18:26:03 2021 +0100
libtracker-data: Flush buffer before resolving INSERT/DELETE/WHERE solution
The triple operations left to be flushed might influence the solution given
by the WHERE clause of the query being handled, ensure these operations
turn into SQL commands before we get the WHERE clause solution.
src/libtracker-data/tracker-sparql.c | 9 +++++++++
1 file changed, 9 insertions(+)
---
diff --git a/src/libtracker-data/tracker-sparql.c b/src/libtracker-data/tracker-sparql.c
index 0761a4773..faddac119 100644
--- a/src/libtracker-data/tracker-sparql.c
+++ b/src/libtracker-data/tracker-sparql.c
@@ -4830,6 +4830,15 @@ translate_Modify (TrackerSparql *sparql,
}
if (_accept (sparql, RULE_TYPE_LITERAL, LITERAL_WHERE)) {
+ GError *flush_error = NULL;
+
+ tracker_data_update_buffer_flush (tracker_data_manager_get_data (sparql->data_manager),
+ &flush_error);
+ if (flush_error) {
+ g_propagate_error (error, flush_error);
+ return FALSE;
+ }
+
where = _skip_rule (sparql, NAMED_RULE_GroupGraphPattern);
solution = get_solution_for_pattern (sparql, where, error);
if (!solution)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]