Commit Graph

6 Commits

Author SHA1 Message Date
Richard Hughes
b3ead97f46 trivial: Fix a -Wdeprecated-declarations issue
G_APPLICATION_FLAGS_NONE was deprecated, but we don't actually need the single
instance functionality, so just use a non-deprecated flag instead.

This fixes Debian CI.
2022-09-06 18:06:55 +01:00
Richard Hughes
e17a107ce1 trivial: Cast the g_signal_connect() object to allow static analysis
This is useful when using https://gitlab.freedesktop.org/tartan/tartan
2022-01-03 22:46:23 +00:00
Richard Hughes
478e44bc19 trivial: Do not use g_assert() in self test code
Note that g_assert() should not be used in unit tests, since it is a
no-op when compiling with G_DISABLE_ASSERT. Use g_assert() in production
code, and g_assert_true() in unit tests.

See https://github.com/fwupd/fwupd/issues/3790
2021-09-24 22:20:21 +01:00
Mario Limonciello
55de39c077 trivial: reformat the whole tree to match new format 2021-08-24 11:18:40 -05:00
Richard Hughes
0b6907e0bb trivial: Fix warning from clang about unused variable 2021-02-08 12:53:32 +00:00
Richard Hughes
3f7ee4d5a1 libfwupd: Return the progress information using the correct GMainContext
We don't want the (shared) progress notifications going to the thread-default
GMainContext by default as this changes behaviour (ABI?) with older libfwupd
versions.

If the client really does want progress notifications to go to a different
GMainContext they it can call fwupd_client_set_main_context() with the desired
context, e.g. g_main_context_get_thread_default() or g_main_context_new().

This has the intended side effect of returning progress and state notifications
to the main thread, which is typically (but not always) the thread that created
the FwupdClient object.
2021-01-08 16:48:34 +00:00