summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* ci: Ignore uncrustify calls resulting in unsuccessful return codesCarlos Garnacho2022-12-071-2/+6
| | | | | | | If for some reason uncrustify gets angry at our file and indent on/off marks, it will result in an error code other than 0. Since in those cases there is no output to diff with, we misinterpret those situations as "the whole file should be deleted", which is far from it.
* Merge branch 'sam/32bit' into 'master'Carlos Garnacho2022-12-062-2/+2
|\ | | | | | | | | libtracker-sparql: Fix some printf format strings See merge request https://gitlab.gnome.org/GNOME/tracker/-/merge_requests/556
| * libtracker-sparql: Fix some printf format stringsSam Thursfield2022-12-062-2/+2
|/ | | | | The size of GSize varies between 64bit and 32bit systems so always use G_GSIZE_FORMAT instead of `%ld`.
* Merge branch 'wip/carlosg/cleanup-sparql-object' into 'master'Carlos Garnacho2022-12-051-241/+240
|\ | | | | | | | | core: Move more transient TrackerSparql data into TrackerSparqlState See merge request https://gitlab.gnome.org/GNOME/tracker/-/merge_requests/550
| * core: Drop tracker_sparql_reset_state()Carlos Garnacho2022-12-051-6/+0
| | | | | | | | | | | | The TrackerSparql object no longer directly contains data that needs to be dropped if rebuilding the SQL query from SPARQL. This function now does nothing, so can be removed.
| * core: Move topmost TrackerContext to TrackerSparqlStateCarlos Garnacho2022-12-051-62/+63
| | | | | | | | | | Now we can avoid keeping this context for long, so move this piece of data to the transient TrackerSparqlState.
| * core: Move cacheable TrackerSelectContext data to TrackerSparqlCarlos Garnacho2022-12-051-4/+13
| | | | | | | | | | | | | | | | After done with query processing, we can keep just small pieces of the TrackerSelectContext data for the (possibly repeatable) query execution step. Move this data to the TrackerSparql, so we can move the TrackerSelectContext to the more transient TrackerSparqlState struct and stick to the essential data.
| * core: Do not process early the SPARQL query on readonly queriesCarlos Garnacho2022-12-051-21/+2
| | | | | | | | | | | | | | We do that, but at the same time we postpone the resulting error until tracker_sparql_execute_cursor(), we can just rely on the paths that are already there for possibly regenerating the SQL string out of the SPARQL string.
| * core: Move graph/service constraint policies to TrackerSparqlStateCarlos Garnacho2022-12-051-58/+59
| | | | | | | | | | We just need to track this state while parsing the SPARQL string, this can be moved to TrackerSparqlState.
| * core: Rename functionCarlos Garnacho2022-12-051-8/+8
| | | | | | | | It was still using a word we agreed on avoiding.
| * core: Move resulting TrackerStringBuilder buffer to TrackerSparqlStateCarlos Garnacho2022-12-051-16/+27
| | | | | | | | | | | | | | After all the query is parsed, we can stick to the resulting SQL string as a gchar*, if/until the query needs to be entirely redone from the initial SPARQL. This means we can move the TrackerStringBuilder itself to be temporary state.
| * core: Move URI base to TrackerSparqlStateCarlos Garnacho2022-12-051-8/+7
| | | | | | | | This is only needed while parsing the query, so can be moved there.
| * core: Shuffle root node initializationCarlos Garnacho2022-12-051-9/+7
| | | | | | | | | | | | Now that we have a tracker_sparql_state_init() function to initialize the TrackerSparqlState, we can fetch the root node of the parser tree there.
| * core: Move anon/named graph arrays to TrackerSparqlStateCarlos Garnacho2022-12-051-29/+29
| | | | | | | | | | This is only needed while parsing the query, so can be moved to TrackerSparqlState.
| * core: Move cached parameters/bindings to TrackerSparqlStateCarlos Garnacho2022-12-051-13/+10
| | | | | | | | | | We just need these supporting hashtables while parsing the query, so these can be moved into TrackerSparqlState.
| * core: Move prefix map to TrackerSparqlStateCarlos Garnacho2022-12-051-9/+17
| | | | | | | | | | | | This is not needed after query parsing, so can be pushed there. As this state needs some initialization, add a tracker_sparql_state_init() function to deal with that.
| * core: Move filter clauses list to TrackerSparqlStateCarlos Garnacho2022-12-051-8/+8
|/ | | | | This is only used while parsing, and is not necessary to preserve with the (possibly long-lived) TrackerSparql object.
* build: Bump version to 3.5.0.alphaCarlos Garnacho2022-12-051-1/+1
|
* libtracker-sparql: Add versioning macros for 3.5.xCarlos Garnacho2022-12-051-0/+20
|
* Release 3.4.23.4.2Carlos Garnacho2022-12-052-1/+11
|
* Update Abkhazian translationNart Tlisha2022-12-021-869/+4
|
* Merge branch 'wip/carlosg/stalls' into 'master'Sam Thursfield2022-11-221-48/+59
|\ | | | | | | | | | | | | libtracker-sparql: Close descriptors asynchronously in TrackerEndpointDBus Closes #386 See merge request https://gitlab.gnome.org/GNOME/tracker/-/merge_requests/551
| * libtracker-sparql: Read updates completely asynchronouslyCarlos Garnacho2022-11-191-44/+53
| | | | | | | | | | | | | | | | | | | | | | | | Even though the updates were being read chunk by chunk asynchronously, it was still the thread/context that spawned the TrackerEndpointDBus what is driving the operation by reading the next chunk, or issuing the update after everything was read. Delegate the whole FD reading to a task in a thread, so it does not need to be driven by the (possibly main) context managing the endpoint. The update is still issued from this thread, mainly to share the FD reading bits between normal and blank node updates.
| * libtracker-sparql: Close descriptors asynchronously in TrackerEndpointDBusCarlos Garnacho2022-11-191-4/+6
| | | | | | | | | | | | | | | | | | | | The QueryRequest and UpdateRequest internal data structures may be freed from the thread that is handling endpoint requests. Avoid closing descriptors from that thread, this is esp. important with the write FDs since there might be data pending to be written and flushed, so it may be a time consuming operation, or it may even stall if the peer is busy with other things. Closes: https://gitlab.gnome.org/GNOME/tracker/-/issues/386
* | Merge branch 'wip/carlosg/numeric-affinity' into 'master'Sam Thursfield2022-11-2267-254/+259
|\ \ | |/ |/| | | | | | | | | core: Handle ROWIDs turned into strings in SparqlPrintIRI() Closes #387 See merge request https://gitlab.gnome.org/GNOME/tracker/-/merge_requests/552
| * core: Handle ROWIDs turned into strings in SparqlPrintIRI()Carlos Garnacho2022-11-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Even though normally we expect ROWIDs to preserve numeric affinity when we proceed to print their IRI in the higher parts of the query, it is not guaranteed by the SQLite documentation: "Whether or not a persistent internal datatype conversion occurs is undefined and may change from one release of SQLite to the next." And this in fact changed for the core/property-paths/alternative-path-3 unit test, where it does the '|' union of text and resource (i.e. ROWIDs) properties. Since SQLite 3.40.0, the SparqlPrintIRI() happening in the topmost select will get SQLITE_TEXT affinity for all ROWID values received through the union. In order to work with both older and newer version of SQLite, attempt to force integer affinity so ROWID IRIs are correctly resolved instead of being interpreted as IRI strings. Closes: https://gitlab.gnome.org/GNOME/tracker/-/issues/387
| * core: Warn on non-absolute IRIs during insertionCarlos Garnacho2022-11-211-0/+3
| | | | | | | | | | | | | | | | | | | | The IRIs being inserted in the triple store should be ensured to be correct, full IRIs. Perform the minimal check here, and warn if the IRI does not at least contain a scheme separator. This at least will raise some warnings if invalid IRIs like <123> or <abc> are inserted by the Tracker user, it will be turned into a GError worthy condition in future versions.
| * tests: Make portal functional test use absolute IRIsCarlos Garnacho2022-11-211-38/+38
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make serialization API tests use absolute IRIsCarlos Garnacho2022-11-215-28/+28
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make insertion functional test use absolute IRIsCarlos Garnacho2022-11-211-1/+1
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make ontology-rollback functional test use absolute IRIsCarlos Garnacho2022-11-211-10/+10
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Use absolute IRIs in ontology-change testsCarlos Garnacho2022-11-2119-40/+40
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make CONSTRAINT tests use absolute IRIsCarlos Garnacho2022-11-2113-22/+23
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make property-path tests use absolute IRIsCarlos Garnacho2022-11-212-4/+4
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make turtle tests use absolute IRIsCarlos Garnacho2022-11-211-4/+4
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * core: Add missing break to turtle file importingCarlos Garnacho2022-11-211-0/+1
| | | | | | | | | | | | If we got an error, we want to break early of this loop, otherwise we'll reuse the already set GError and fall into further warnings that might obscure the original issue.
| * tests: Make RDF list tests use absolute IRIsCarlos Garnacho2022-11-212-2/+2
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make langstring tests use absolute IRIsCarlos Garnacho2022-11-216-10/+10
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make FILTER expression tests use absolute IRIsCarlos Garnacho2022-11-213-5/+5
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make DESCRIBE tests use absolute IRIsCarlos Garnacho2022-11-216-55/+55
| | | | | | | | Do not rely on our loose interpretation of IRIs to make tests work.
| * tests: Make CONSTRUCT tests use absolute IRIsCarlos Garnacho2022-11-214-34/+34
|/ | | | Do not rely on our loose interpretation of IRIs to make tests work.
* Update Dutch translationNathan Follens2022-11-011-83/+86
|
* Update Abkhazian translationNart Tlisha2022-10-311-3046/+4
|
* Release 3.4.13.4.1Carlos Garnacho2022-10-262-1/+15
|
* Merge branch 'wip/carlosg/valgrind-fixes' into 'master'Carlos Garnacho2022-10-265-21/+16
|\ | | | | | | | | Fixes for issues detected by valgrind See merge request https://gitlab.gnome.org/GNOME/tracker/-/merge_requests/549
| * libtracker-sparql/core: Ensure update log flushing harderCarlos Garnacho2022-10-241-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Our update log is a fixed size, we (usually) try hard that it remains within it, and avoid GArray resizes which in turn result in GHashTable entries suddenly pointing to invalid memory. This however may break if many multivalued property additions on the same graph/subject/predicate happen. This is seen in valgrind as: ==477545== Invalid read of size 8 ==477545== at 0x4C67E9A: tracker_data_log_entry_equal (tracker-data-update.c:231) ==477545== by 0x48E4AF1: UnknownInlinedFun (ghash.c:495) ==477545== by 0x48E4AF1: g_hash_table_lookup (ghash.c:1540) ==477545== by 0x4C685F7: log_entry_for_single_value_property (tracker-data-update.c:768) ==477545== by 0x4C6A4A4: cache_insert_metadata_decomposed (tracker-data-update.c:2215) ==477545== by 0x4C6C1DD: tracker_data_insert_statement_with_string (tracker-data-update.c:2922) ==477545== by 0x4C6C400: tracker_data_insert_statement (tracker-data-update.c:2826) ==477545== by 0x4C8F94D: tracker_sparql_apply_quad (tracker-sparql.c:2239) ==477545== by 0x4C8FC66: translate_GraphNode (tracker-sparql.c:7466) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C82636: translate_Object (tracker-sparql.c:6537) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C89655: translate_ObjectList (tracker-sparql.c:6522) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C8C47D: translate_PropertyListNotEmpty (tracker-sparql.c:6491) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C82995: translate_TriplesSameSubject (tracker-sparql.c:6406) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84E3E: translate_TriplesTemplate (tracker-sparql.c:5206) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== Address 0x8688768 is 104 bytes inside a block of size 4,096 free'd ==477545== at 0x48466AF: realloc (vg_replace_malloc.c:1437) ==477545== by 0x49095BF: g_realloc (gmem.c:201) ==477545== by 0x48CEF52: g_array_maybe_expand (garray.c:1000) ==477545== by 0x48CF2DF: g_array_append_vals (garray.c:528) ==477545== by 0x4C68797: log_entry_for_multi_value_property (tracker-data-update.c:748) ==477545== by 0x4C6A433: cache_insert_metadata_decomposed (tracker-data-update.c:2211) ==477545== by 0x4C6BFF9: tracker_data_insert_statement_with_uri (tracker-data-update.c:2880) ==477545== by 0x4C6C497: tracker_data_insert_statement (tracker-data-update.c:2824) ==477545== by 0x4C8F94D: tracker_sparql_apply_quad (tracker-sparql.c:2239) ==477545== by 0x4C8FC66: translate_GraphNode (tracker-sparql.c:7466) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C82636: translate_Object (tracker-sparql.c:6537) ==477545== by 0x4C89769: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C89769: translate_ObjectList (tracker-sparql.c:6525) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C8C47D: translate_PropertyListNotEmpty (tracker-sparql.c:6491) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C82995: translate_TriplesSameSubject (tracker-sparql.c:6406) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84E3E: translate_TriplesTemplate (tracker-sparql.c:5206) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== by 0x4C84ECF: translate_TriplesTemplate (tracker-sparql.c:5210) ==477545== by 0x4C8219F: _call_rule_func (tracker-sparql.c:9805) ==477545== Block was alloc'd at ==477545== at 0x484178A: malloc (vg_replace_malloc.c:380) ==477545== by 0x484670B: realloc (vg_replace_malloc.c:1437) ==477545== by 0x49095BF: g_realloc (gmem.c:201) ==477545== by 0x48CEF52: g_array_maybe_expand (garray.c:1000) ==477545== by 0x48CF07C: g_array_sized_new (garray.c:287) ==477545== by 0x4C6C942: tracker_data_begin_transaction (tracker-data-update.c:3056) ==477545== by 0x4C6C995: tracker_data_begin_ontology_transaction (tracker-data-update.c:3081) ==477545== by 0x4C63F2E: tracker_data_manager_initable_init (tracker-data-manager.c:4317) ==477545== by 0x4C9E724: tracker_direct_connection_initable_init (tracker-direct.c:493) ==477545== by 0x4A656B7: g_initable_new_valist (ginitable.c:250) ==477545== by 0x4A657AC: g_initable_new (ginitable.c:164) ==477545== by 0x4C9F5AB: tracker_direct_connection_new (tracker-direct.c:1562) ==477545== by 0x4C47D20: tracker_sparql_connection_new (tracker-connection.c:1025) ==477545== by 0x40AF7B: setup_connection_and_endpoint (tracker-main.c:823) ==477545== by 0x40AF7B: main (tracker-main.c:1062) Ensure to flush harder, even if the resource would stay the same, this avoids the log array from growing past this fixed limit.
| * libtracker-sparql/core: Unlink TrackerDBStatement before removing from HTCarlos Garnacho2022-10-241-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The hashtable destroy functions may result in the TrackerDBStatement being freed, so trying to access the MRU head after that will result in invalid memory access, seen in valgrind as: ==477545== Invalid write of size 8 ==477545== at 0x4C71DF9: tracker_db_statement_mru_insert (tracker-db-interface-sqlite.c:2656) ==477545== by 0x4C6AFF8: tracker_data_ensure_update_statement (tracker-data-update.c:1219) ==477545== by 0x4C6AFF8: tracker_data_flush_log (tracker-data-update.c:1242) ==477545== by 0x4C6AFF8: tracker_data_update_buffer_flush (tracker-data-update.c:1550) ==477545== by 0x4C6BA79: tracker_data_update_buffer_might_flush (tracker-data-update.c:1605) ==477545== by 0x4C6BADF: resource_buffer_switch (tracker-data-update.c:2534) ==477545== by 0x4C6BF2C: tracker_data_insert_statement_with_uri (tracker-data-update.c:2857) ==477545== by 0x4C6C497: tracker_data_insert_statement (tracker-data-update.c:2824) ==477545== by 0x4C6D897: update_resource_property (tracker-data-update.c:3489) ==477545== by 0x4C6D4C4: update_resource_single (tracker-data-update.c:3554) ==477545== by 0x4C6D847: update_resource_property (tracker-data-update.c:3442) ==477545== by 0x4C6D673: update_resource_single (tracker-data-update.c:3593) ==477545== by 0x4C6D847: update_resource_property (tracker-data-update.c:3442) ==477545== by 0x4C6D673: update_resource_single (tracker-data-update.c:3593) ==477545== by 0x4C6DA3D: tracker_data_update_resource (tracker-data-update.c:3626) ==477545== by 0x4CA0498: tracker_direct_batch_update (tracker-direct-batch.c:221) ==477545== by 0x4C9F8B4: update_thread_func (tracker-direct.c:286) ==477545== by 0x492F8A1: g_thread_pool_thread_proxy.lto_priv.0 (gthreadpool.c:352) ==477545== by 0x492A771: g_thread_proxy (gthread.c:831) ==477545== by 0x4D975B4: start_thread (pthread_create.c:442) ==477545== by 0x4E17F03: clone (clone.S:100) ==477545== Address 0xb2ccbe0 is 64 bytes inside a block of size 72 free'd ==477545== at 0x48440E4: free (vg_replace_malloc.c:872) ==477545== by 0x490584C: g_free (gmem.c:229) ==477545== by 0x491FE93: g_slice_free1 (gslice.c:1185) ==477545== by 0x4BFF63B: g_type_free_instance (gtype.c:2010) ==477545== by 0x48EC3C6: UnknownInlinedFun (ghash.c:1774) ==477545== by 0x48EC3C6: g_hash_table_remove (ghash.c:1802) ==477545== by 0x4C71DF5: tracker_db_statement_mru_insert (tracker-db-interface-sqlite.c:2655) ==477545== by 0x4C6AFF8: tracker_data_ensure_update_statement (tracker-data-update.c:1219) ==477545== by 0x4C6AFF8: tracker_data_flush_log (tracker-data-update.c:1242) ==477545== by 0x4C6AFF8: tracker_data_update_buffer_flush (tracker-data-update.c:1550) ==477545== by 0x4C6BA79: tracker_data_update_buffer_might_flush (tracker-data-update.c:1605) ==477545== by 0x4C6BADF: resource_buffer_switch (tracker-data-update.c:2534) ==477545== by 0x4C6BF2C: tracker_data_insert_statement_with_uri (tracker-data-update.c:2857) ==477545== by 0x4C6C497: tracker_data_insert_statement (tracker-data-update.c:2824) ==477545== by 0x4C6D897: update_resource_property (tracker-data-update.c:3489) ==477545== by 0x4C6D4C4: update_resource_single (tracker-data-update.c:3554) ==477545== by 0x4C6D847: update_resource_property (tracker-data-update.c:3442) ==477545== by 0x4C6D673: update_resource_single (tracker-data-update.c:3593) ==477545== by 0x4C6D847: update_resource_property (tracker-data-update.c:3442) ==477545== by 0x4C6D673: update_resource_single (tracker-data-update.c:3593) ==477545== by 0x4C6DA3D: tracker_data_update_resource (tracker-data-update.c:3626) ==477545== by 0x4CA0498: tracker_direct_batch_update (tracker-direct-batch.c:221) ==477545== by 0x4C9F8B4: update_thread_func (tracker-direct.c:286) ==477545== by 0x492F8A1: g_thread_pool_thread_proxy.lto_priv.0 (gthreadpool.c:352) ==477545== by 0x492A771: g_thread_proxy (gthread.c:831) ==477545== by 0x4D975B4: start_thread (pthread_create.c:442) ==477545== by 0x4E17F03: clone (clone.S:100) ==477545== Block was alloc'd at ==477545== at 0x484186F: malloc (vg_replace_malloc.c:381) ==477545== by 0x4909008: g_malloc (gmem.c:130) ==477545== by 0x4920865: g_slice_alloc (gslice.c:1074) ==477545== by 0x4920E9C: g_slice_alloc0 (gslice.c:1100) ==477545== by 0x4C0500B: g_type_create_instance (gtype.c:1913) ==477545== by 0x4BEAC4E: g_object_new_internal (gobject.c:2226) ==477545== by 0x4BEC247: g_object_new_with_properties (gobject.c:2387) ==477545== by 0x4BECFF0: g_object_new (gobject.c:2035) ==477545== by 0x4C71F4F: tracker_db_statement_sqlite_new (tracker-db-interface-sqlite.c:2985) ==477545== by 0x4C71F4F: tracker_db_interface_create_statement (tracker-db-interface-sqlite.c:2751) ==477545== by 0x4C72155: tracker_db_interface_create_vstatement (tracker-db-interface-sqlite.c:2784) ==477545== by 0x4C6B232: tracker_data_ensure_update_statement (tracker-data-update.c:1177) ==477545== by 0x4C6B232: tracker_data_flush_log (tracker-data-update.c:1242) ==477545== by 0x4C6B232: tracker_data_update_buffer_flush (tracker-data-update.c:1550) ==477545== by 0x4C6C6A0: tracker_data_update_statement (tracker-data-update.c:2994) ==477545== by 0x4C60363: tracker_data_ontology_process_statement (tracker-data-manager.c:2346) ==477545== by 0x4C60363: import_ontology_file (tracker-data-manager.c:2389) ==477545== by 0x4C6421D: tracker_data_manager_initable_init (tracker-data-manager.c:4398) ==477545== by 0x4C9E724: tracker_direct_connection_initable_init (tracker-direct.c:493) ==477545== by 0x4A656B7: g_initable_new_valist (ginitable.c:250) ==477545== by 0x4A657AC: g_initable_new (ginitable.c:164) ==477545== by 0x4C9F5AB: tracker_direct_connection_new (tracker-direct.c:1562) ==477545== by 0x4C47D20: tracker_sparql_connection_new (tracker-connection.c:1025) ==477545== by 0x40AF7B: setup_connection_and_endpoint (tracker-main.c:823) ==477545== by 0x40AF7B: main (tracker-main.c:1062)
| * libtracker-sparql/direct: Plug possible leaks on statement cancellationCarlos Garnacho2022-10-241-4/+2
| | | | | | | | | | | | Unref the task consistently after g_task_run_in_thread(), so it is properly disposed after the callback finishes execution. This avoids these callbacks from having to free the task on each return path, which they didn't.
| * libtracker-sparql/core: Plug leak in triples vtabCarlos Garnacho2022-10-241-7/+1
| | | | | | | | | | | | | | | | | | | | | | The TrackerTriplesVTab struct created to back the tracker_triples table up is not being properly freed. Since this is an eponymous-only table, we never drop the table, thus the xDisconnect vfunc is the right one for us. In case we ever wanted to drop the table, make the xDestroy method the same, since this virtual table creates no supporting non-virtual tables.
| * libtracker-sparql/core: Plug leakCarlos Garnacho2022-10-241-1/+3
| | | | | | | | | | If the binding was already referenced, the lookup string was not being freed.