From 43a09b36460b2bcea29143867c66b7174f152b4a Mon Sep 17 00:00:00 2001 From: Alexander Larsson Date: Tue, 15 Dec 2015 14:34:52 +0100 Subject: [PATCH] Fix unused variable warnings --- app/xdg-app-builtins-add-remote.c | 1 - app/xdg-app-builtins-install.c | 2 -- app/xdg-app-builtins-ls-remote.c | 1 - builder/builder-cache.c | 1 - builder/builder-manifest.c | 5 ----- builder/builder-options.c | 1 - builder/builder-source-file.c | 2 -- builder/builder-source-git.c | 1 - common/xdg-app-dir.c | 3 --- lib/xdg-app-installation.c | 1 - lib/xdg-app-remote.c | 1 - 11 files changed, 19 deletions(-) diff --git a/app/xdg-app-builtins-add-remote.c b/app/xdg-app-builtins-add-remote.c index 0f523248..4b795f2e 100644 --- a/app/xdg-app-builtins-add-remote.c +++ b/app/xdg-app-builtins-add-remote.c @@ -148,7 +148,6 @@ xdg_app_builtin_add_remote (int argc, char **argv, g_autoptr(GOptionContext) context = NULL; g_autoptr(XdgAppDir) dir = NULL; g_autoptr(GVariantBuilder) optbuilder = NULL; - g_autoptr(GHashTable) refs = NULL; g_autoptr(GFile) file = NULL; g_autofree char *title = NULL; g_autofree char *remote_url = NULL; diff --git a/app/xdg-app-builtins-install.c b/app/xdg-app-builtins-install.c index 97373a83..a463bdae 100644 --- a/app/xdg-app-builtins-install.c +++ b/app/xdg-app-builtins-install.c @@ -263,11 +263,9 @@ xdg_app_builtin_install_bundle (int argc, char **argv, GCancellable *cancellable g_autoptr(GFile) deploy_base = NULL; g_autoptr(GFile) file = NULL; g_autoptr(GFile) gpg_tmp_file = NULL; - g_autoptr(GBytes) bytes = NULL; const char *filename; g_autofree char *ref = NULL; g_autofree char *origin = NULL; - g_autofree char *checksum = NULL; gboolean created_deploy_base = FALSE; gboolean added_remote = FALSE; g_autofree char *to_checksum = NULL; diff --git a/app/xdg-app-builtins-ls-remote.c b/app/xdg-app-builtins-ls-remote.c index b1eca8e8..08a143ee 100644 --- a/app/xdg-app-builtins-ls-remote.c +++ b/app/xdg-app-builtins-ls-remote.c @@ -56,7 +56,6 @@ xdg_app_builtin_ls_remote (int argc, char **argv, GCancellable *cancellable, GEr g_autoptr(GPtrArray) names = NULL; int i; const char *repository; - g_autofree char *url = NULL; context = g_option_context_new (" REMOTE - Show available runtimes and applications"); diff --git a/builder/builder-cache.c b/builder/builder-cache.c index 0cd1fcbb..1ab93059 100644 --- a/builder/builder-cache.c +++ b/builder/builder-cache.c @@ -376,7 +376,6 @@ builder_cache_get_changes (BuilderCache *self, g_autoptr(GFile) parent_root = NULL; g_autoptr(GFile) parent_files = NULL; g_autoptr(GVariant) variant = NULL; - g_autoptr(GHashTable) owned = NULL; g_autofree char *parent_commit = NULL; int i; diff --git a/builder/builder-manifest.c b/builder/builder-manifest.c index 5be76fd0..7d56e694 100644 --- a/builder/builder-manifest.c +++ b/builder/builder-manifest.c @@ -541,10 +541,7 @@ builder_manifest_init_app_dir (BuilderManifest *self, { GFile *app_dir = builder_context_get_app_dir (context); g_autofree char *app_dir_path = g_file_get_path (app_dir); - g_autoptr(GSubprocessLauncher) launcher = NULL; g_autoptr(GSubprocess) subp = NULL; - g_autofree char *cwd = NULL; - g_autoptr(GPtrArray) args = NULL; if (self->app_id == NULL) { @@ -782,7 +779,6 @@ foreach_file_helper (BuilderManifest *self, GError **error) { g_auto(GLnxDirFdIterator) source_iter = {0}; - glnx_fd_close int destination_dfd = -1; struct dirent *dent; g_autoptr(GError) my_error = NULL; @@ -798,7 +794,6 @@ foreach_file_helper (BuilderManifest *self, while (TRUE) { struct stat stbuf; - g_autofree char *source_printable = NULL; if (!glnx_dirfd_iterator_next_dent (&source_iter, &dent, NULL, error)) return FALSE; diff --git a/builder/builder-options.c b/builder/builder-options.c index 6f003d5d..8657a827 100644 --- a/builder/builder-options.c +++ b/builder/builder-options.c @@ -301,7 +301,6 @@ builder_options_deserialize_property (JsonSerializable *serializable, else if (JSON_NODE_TYPE (property_node) == JSON_NODE_OBJECT) { JsonObject *object = json_node_get_object (property_node); - g_autoptr(GPtrArray) env = g_ptr_array_new_with_free_func (g_free); g_autoptr(GHashTable) hash = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_object_unref); g_autoptr(GList) members = NULL; GList *l; diff --git a/builder/builder-source-file.c b/builder/builder-source-file.c index f1ac0642..a27f0e9e 100644 --- a/builder/builder-source-file.c +++ b/builder/builder-source-file.c @@ -420,8 +420,6 @@ builder_source_file_update (BuilderSource *source, { BuilderSourceFile *self = BUILDER_SOURCE_FILE (source); g_autoptr(GFile) src = NULL; - g_autoptr(GFile) dest_file = NULL; - g_autofree char *dest_filename = NULL; gboolean is_local, is_inline; src = get_source_file (self, context, &is_local, &is_inline, error); diff --git a/builder/builder-source-git.c b/builder/builder-source-git.c index 559fd944..52d40f8d 100644 --- a/builder/builder-source-git.c +++ b/builder/builder-source-git.c @@ -373,7 +373,6 @@ builder_source_git_download (BuilderSource *source, GError **error) { BuilderSourceGit *self = BUILDER_SOURCE_GIT (source); - g_autoptr(GFile) mirror_dir = NULL; g_autofree char *url = NULL; url = get_url (self, context, error); diff --git a/common/xdg-app-dir.c b/common/xdg-app-dir.c index 8f9f4830..725c33e4 100644 --- a/common/xdg-app-dir.c +++ b/common/xdg-app-dir.c @@ -289,9 +289,6 @@ xdg_app_dir_load_override (XdgAppDir *self, GKeyFile * xdg_app_load_override_keyfile (const char *app_id, gboolean user, GError **error) { - g_autoptr(GFile) base_dir = NULL; - g_autoptr(GFile) override_dir = NULL; - g_autoptr(GFile) file = NULL; g_autofree char *metadata_contents = NULL; gsize metadata_size; g_autoptr(GKeyFile) metakey = g_key_file_new (); diff --git a/lib/xdg-app-installation.c b/lib/xdg-app-installation.c index 027e4828..5773f4a5 100644 --- a/lib/xdg-app-installation.c +++ b/lib/xdg-app-installation.c @@ -336,7 +336,6 @@ xdg_app_installation_load_app_overrides (XdgAppInstallation *self, GError **error) { XdgAppInstallationPrivate *priv = xdg_app_installation_get_instance_private (self); - g_autoptr(GBytes) bytes = NULL; g_autofree char *metadata_contents = NULL; gsize metadata_size; diff --git a/lib/xdg-app-remote.c b/lib/xdg-app-remote.c index 6825c57a..a9b355d9 100644 --- a/lib/xdg-app-remote.c +++ b/lib/xdg-app-remote.c @@ -235,7 +235,6 @@ xdg_app_remote_fetch_ref_sync (XdgAppRemote *self, GError **error) { XdgAppRemotePrivate *priv = xdg_app_remote_get_instance_private (self); - g_autoptr(GPtrArray) refs = g_ptr_array_new_with_free_func (g_object_unref); g_autoptr(GHashTable) ht = NULL; g_autofree char *ref = NULL; const char *checksum;