Initialize the schema_name so that NULL is returned when the schema name
is absent, instead of an uninitialized memory. Mark return value as
nullable to indicate this for introspection and documentation.
This fixes:
==22678== 48 bytes in 1 blocks are definitely lost in loss record 1,045 of 1,560
==22678== at 0x4C28C50: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==22678== by 0x6002FCC: g_malloc (gmem.c:94)
==22678== by 0x60032AE: g_malloc_n (gmem.c:330)
==22678== by 0x601DBF0: g_strdup (gstrfuncs.c:363)
==22678== by 0x4E6508B: on_create_item_called (secret-paths.c:1991)
==22678== by 0x5A3346D: g_task_return_now (gtask.c:1104)
==22678== by 0x5A33575: g_task_return (gtask.c:1162)
==22678== by 0x5A33E76: g_task_return_pointer (gtask.c:1537)
==22678== by 0x5A9BB7D: g_dbus_connection_call_done (gdbusconnection.c:5704)
==22678== by 0x5A3346D: g_task_return_now (gtask.c:1104)
==22678== by 0x5A334B6: complete_in_idle_cb (gtask.c:1118)
==22678== by 0x5FFD3D0: g_idle_dispatch (gmain.c:5441)
==22678== by 0x5FFAA18: g_main_dispatch (gmain.c:3154)
==22678== by 0x5FFB85C: g_main_context_dispatch (gmain.c:3769)
==22678== by 0x5FFBA40: g_main_context_iterate (gmain.c:3840)
==22678== by 0x5FFBE66: g_main_loop_run (gmain.c:4034)
==22678== by 0x4E7C9E4: loop_wait_until (egg-testing.c:151)
==22678== by 0x4E7C85C: egg_test_wait_until (egg-testing.c:105)
==22678== by 0x402D22: test_create_async (test-item.c:245)
==22678== by 0x60258FA: test_case_run (gtestutils.c:2158)
==22678== by 0x6025CBB: g_test_run_suite_internal (gtestutils.c:2241)
==22678== by 0x6025D64: g_test_run_suite_internal (gtestutils.c:2253)
==22678== by 0x6025F7B: g_test_run_suite (gtestutils.c:2328)
==22678== by 0x6024C1C: g_test_run (gtestutils.c:1596)
==22678== by 0x4E7CA3E: egg_tests_run_with_loop (egg-testing.c:167)
==22678== by 0x406B52: main (test-item.c:887)
https://bugzilla.gnome.org/show_bug.cgi?id=756766
This fixes:
==20768== 67 (40 direct, 27 indirect) bytes in 1 blocks are definitely lost in loss record 1,133 of 1,588
==20768== at 0x4C28C50: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==20768== by 0x6002FCC: g_malloc (gmem.c:94)
==20768== by 0x601B523: g_slice_alloc (gslice.c:1007)
==20768== by 0x601B563: g_slice_alloc0 (gslice.c:1032)
==20768== by 0x4E5FB64: secret_value_new_full (secret-value.c:140)
==20768== by 0x4E67B63: service_decode_aes_secret (secret-session.c:457)
==20768== by 0x4E67D6B: _secret_session_decode_secret (secret-session.c:513)
==20768== by 0x4E50A61: on_item_load_secret (secret-item.c:1157)
==20768== by 0x5A3346D: g_task_return_now (gtask.c:1104)
==20768== by 0x5A33575: g_task_return (gtask.c:1162)
==20768== by 0x5A33E76: g_task_return_pointer (gtask.c:1537)
==20768== by 0x5AAC7E6: reply_cb (gdbusproxy.c:2579)
==20768== by 0x5A3346D: g_task_return_now (gtask.c:1104)
==20768== by 0x5A33575: g_task_return (gtask.c:1162)
==20768== by 0x5A33E76: g_task_return_pointer (gtask.c:1537)
==20768== by 0x5A9BB7D: g_dbus_connection_call_done (gdbusconnection.c:5704)
==20768== by 0x5A3346D: g_task_return_now (gtask.c:1104)
==20768== by 0x5A334B6: complete_in_idle_cb (gtask.c:1118)
==20768== by 0x5FFD3D0: g_idle_dispatch (gmain.c:5441)
==20768== by 0x5FFAA18: g_main_dispatch (gmain.c:3154)
==20768== by 0x5FFB85C: g_main_context_dispatch (gmain.c:3769)
==20768== by 0x5FFBA40: g_main_context_iterate (gmain.c:3840)
==20768== by 0x5FFBE66: g_main_loop_run (gmain.c:4034)
==20768== by 0x4E510DA: secret_item_load_secret_sync (secret-item.c:1311)
==20768== by 0x405238: test_load_secret_sync (test-item.c:592)
==20768== by 0x60258FA: test_case_run (gtestutils.c:2158)
==20768== by 0x6025CBB: g_test_run_suite_internal (gtestutils.c:2241)
==20768== by 0x6025D64: g_test_run_suite_internal (gtestutils.c:2253)
==20768== by 0x6025F7B: g_test_run_suite (gtestutils.c:2328)
==20768== by 0x6024C1C: g_test_run (gtestutils.c:1596)
==20768== by 0x4E7CA25: egg_tests_run_with_loop (egg-testing.c:167)
==20768== by 0x406B52: main (test-item.c:887)
https://bugzilla.gnome.org/show_bug.cgi?id=756766
Allow parallel building and testing by using a single Makefile.am
Implement parallel testing using TAP, with various drivers and
compilers living in the build/ directory.
Fix all sorts of issues that this caused, including builddir != srcdir,
leaks in tests and so on.
It would have been nice to break out all the above into separate
commits ... blush.
* This is necessary because sometimes we don't want to complain,
for expected errors, when running nested operations.
* The fact that we have to do this is silly, and soon there
will be a solution in glib itself.
https://bugzilla.gnome.org/show_bug.cgi?id=688165
* C callers need to use libsecret-0 pkg-config file for stable and
libsecret-unstable for unstable stuff.
* Vala callers need to '--pkg libsecret-unstable' for unstable
* GObject Introspection callers need to use the SecretUnstable package
* Death by a thousand paper cuts from gir and vapi not liking
the fact that the secret.h file was not usable uninstalled
and installed in the same way.