Skip to content

libtracker-sparql: Fix out parameter in VAPI/Vala files

Carlos Garnacho requested to merge wip/carlosg/fix-cursor-string-length into master

This argument was made nullable in commit 5ea2e77f. While this sounds what we want (the argument is nullable in C API and the vmethod). This makes Vala introduce a double indirection for the out parameter, so the argument ends up as "glong**" in the generated C code.

Of course, this breaks the interaction with C code and cursor class definition expecting a "glong*" there, extra points for the C compiler error being silenced. Undoing these specific changes from that commit makes Vala and C code agree again about the levels of indirection.

This broke callers that rely on the string length being meaningful, a glaring known broken case is the portal, as it breaks the redirection/serialization of cursors to sandboxed apps.

Fixes: #282 (closed)

Merge request reports