Remove unused variables

This fixes warnings from clang
This commit is contained in:
Alexander Larsson committed 2016-05-09 12:49:54 +02:00
1 parent 5e9b247d26
commit 4f9ea6bb57
7 files changed
+2 -19

No files matched your search

+1 -4
View File
@@ -256,9 +256,6 @@ build_bundle (OstreeRepo *repo, GFile *file,
#if defined(HAVE_LIBARCHIVE) && defined(HAVE_OSTREE_EXPORT_PATH_PREFIX)
GLNX_DEFINE_CLEANUP_FUNCTION (void *, flatpak_local_free_read_archive, archive_read_free)
#define free_read_archive __attribute__((cleanup (flatpak_local_free_read_archive)))
GLNX_DEFINE_CLEANUP_FUNCTION (void *, flatpak_local_free_write_archive, archive_write_free)
#define free_write_archive __attribute__((cleanup (flatpak_local_free_write_archive)))
@@ -752,7 +749,7 @@ build_oci (OstreeRepo *repo, GFile *file,
"This version of flatpak is not compiled with libarchive support");
return FALSE;
#else
struct free_write_archive archive *a = NULL;
free_write_archive struct archive *a = NULL;
OstreeRepoExportArchiveOptions opts = { 0, };
g_autoptr(GFile) root = NULL;
g_autoptr(GFile) files = NULL;
@@ -276,7 +276,6 @@ flatpak_builtin_build_import (int argc, char **argv, GCancellable *cancellable,
g_autoptr(GFile) file = NULL;
g_autoptr(GFile) repofile = NULL;
g_autoptr(OstreeRepo) repo = NULL;
g_autoptr(GBytes) gpg_data = NULL;
const char *location;
const char *filename;
-4
View File
@@ -681,7 +681,6 @@ flatpak_create_deploy_data_from_old (FlatpakDir *self,
g_autofree char *old_origin = NULL;
g_autofree char *commit = NULL;
g_auto(GStrv) old_subpaths = NULL;
g_autoptr(GFile) root = NULL;
g_autoptr(GFile) origin = NULL;
guint64 installed_size;
@@ -714,7 +713,6 @@ flatpak_dir_get_deploy_data (FlatpakDir *self,
g_autoptr(GError) my_error = NULL;
char *data = NULL;
gsize data_size;
g_autofree char *active = NULL;
deploy_dir = flatpak_dir_get_if_deployed (self, ref, NULL, cancellable);
if (deploy_dir == NULL)
@@ -2723,8 +2721,6 @@ flatpak_dir_deploy_update (FlatpakDir *self,
GCancellable *cancellable,
GError **error)
{
g_autofree char *previous_deployment = NULL;
g_autoptr(GError) my_error = NULL;
g_autoptr(GVariant) old_deploy_data = NULL;
g_auto(GLnxLockFile) lock = GLNX_LOCK_FILE_INIT;
-3
View File
@@ -1525,10 +1525,8 @@ flatpak_summary_lookup_ref (GVariant *summary, const char *ref, char **out_check
int pos;
g_autoptr(GVariant) refdata = NULL;
g_autoptr(GVariant) reftargetdata = NULL;
g_autoptr(GVariant) commit_data = NULL;
guint64 commit_size;
g_autoptr(GVariant) commit_csum_v = NULL;
g_autoptr(GBytes) commit_bytes = NULL;
if (!flatpak_variant_bsearch_str (refs, ref, &pos))
return FALSE;
@@ -2918,7 +2916,6 @@ flatpak_allocate_tmpdir (int tmpdir_dfd,
while (tmpdir_name == NULL)
{
gs_dirfd_iterator_cleanup GSDirFdIterator child_dfd_iter = { 0, };
struct dirent *dent;
glnx_fd_close int existing_tmpdir_fd = -1;
g_autoptr(GError) local_error = NULL;
+1 -1
View File
@@ -30,4 +30,4 @@ xdg_document_portal_SOURCES = \
$(NULL)
xdg_document_portal_LDADD = $(BASE_LIBS) $(FUSE_LIBS) libflatpak-common.la
xdg_document_portal_CFLAGS = $(BASE_CFLAGS) $(OSTREE_CFLAGS) $(SOUP_CFLAGS) $(XAUTH_LIBS) $(FUSE_CFLAGS) -I$(srcdir)/document-portal -I$(builddir)/document-portal
xdg_document_portal_CFLAGS = $(BASE_CFLAGS) $(OSTREE_CFLAGS) $(SOUP_CFLAGS) $(FUSE_CFLAGS) -I$(srcdir)/document-portal -I$(builddir)/document-portal
-4
View File
@@ -834,8 +834,6 @@ flatpak_installation_install_bundle (FlatpakInstallation *self,
g_autoptr(GFile) deploy_base = NULL;
g_autoptr(FlatpakDir) dir_clone = NULL;
FlatpakInstalledRef *result = NULL;
g_autoptr(GError) local_error = NULL;
g_auto(GLnxLockFile) lock = GLNX_LOCK_FILE_INIT;
g_autoptr(GVariant) metadata = NULL;
g_autofree char *origin = NULL;
g_auto(GStrv) parts = NULL;
@@ -947,8 +945,6 @@ flatpak_installation_install (FlatpakInstallation *self,
g_autoptr(GMainContext) main_context = NULL;
g_autoptr(OstreeAsyncProgress) ostree_progress = NULL;
FlatpakInstalledRef *result = NULL;
g_autoptr(GError) local_error = NULL;
g_auto(GLnxLockFile) lock = GLNX_LOCK_FILE_INIT;
ref = flatpak_compose_ref (kind == FLATPAK_REF_KIND_APP, name, branch, arch, error);
if (ref == NULL)
-2
View File
@@ -55,8 +55,6 @@ handle_deploy (FlatpakSystemHelper *object,
g_autoptr(GFile) path = g_file_new_for_path (arg_repo_path);
g_autoptr(GError) error = NULL;
g_autoptr(GFile) deploy_dir = NULL;
g_autoptr(AutoPolkitSubject) subject = NULL;
g_autoptr(AutoPolkitDetails) details = NULL;
gboolean is_update;
g_autoptr(GMainContext) main_context = NULL;