main: Move GCancellable to toplevel
This is just cleaner, and makes the builtins slightly more of a library, which in turn makes it easier to turn them into real API.
This commit is contained in:
1 parent
272274f0af
commit
aac52cb9f7
23 files changed
+47
-59
No files matched your search
@@ -53,7 +53,7 @@ on_checksum_received (GObject *obj,
|
||||
}
|
||||
|
||||
gboolean
|
||||
ostree_builtin_checksum (int argc, char **argv, GFile *repo_path_path, GError **error)
|
||||
ostree_builtin_checksum (int argc, char **argv, GFile *repo_path_path, GCancellable *cancellable, GError **error)
|
||||
{
|
||||
GOptionContext *context;
|
||||
gboolean ret = FALSE;
|
||||
@@ -77,7 +77,7 @@ ostree_builtin_checksum (int argc, char **argv, GFile *repo_path_path, GError **
|
||||
|
||||
data.loop = g_main_loop_new (NULL, FALSE);
|
||||
data.error = error;
|
||||
ostree_checksum_file_async (f, OSTREE_OBJECT_TYPE_FILE, G_PRIORITY_DEFAULT, NULL, on_checksum_received, &data);
|
||||
ostree_checksum_file_async (f, OSTREE_OBJECT_TYPE_FILE, G_PRIORITY_DEFAULT, cancellable, on_checksum_received, &data);
|
||||
|
||||
g_main_loop_run (data.loop);
|
||||
|
||||
|
||||
Reference in new issue
Block a user