/* downloader.c generated by valac 0.22.0.39-4730, the Vala compiler
 * generated from downloader.vala, do not modify */

/* This file is part of GNOME Boxes. License: LGPLv2+*/

#include <glib.h>
#include <glib-object.h>
#include <stdlib.h>
#include <string.h>
#include <gio/gio.h>
#include <libcommon.h>
#include <libsoup/soup.h>
#include <osinfo/osinfo.h>
#include <float.h>
#include <math.h>
#include <gtk/gtk.h>
#include <gdk-pixbuf/gdk-pixbuf.h>
#include <gobject/gvaluecollector.h>


#define BOXES_TYPE_DOWNLOAD (boxes_download_get_type ())
#define BOXES_DOWNLOAD(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), BOXES_TYPE_DOWNLOAD, BoxesDownload))
#define BOXES_DOWNLOAD_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), BOXES_TYPE_DOWNLOAD, BoxesDownloadClass))
#define BOXES_IS_DOWNLOAD(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), BOXES_TYPE_DOWNLOAD))
#define BOXES_IS_DOWNLOAD_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), BOXES_TYPE_DOWNLOAD))
#define BOXES_DOWNLOAD_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), BOXES_TYPE_DOWNLOAD, BoxesDownloadClass))

typedef struct _BoxesDownload BoxesDownload;
typedef struct _BoxesDownloadClass BoxesDownloadClass;
typedef struct _BoxesDownloadPrivate BoxesDownloadPrivate;
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
typedef struct _BoxesParamSpecDownload BoxesParamSpecDownload;

#define BOXES_TYPE_DOWNLOADER (boxes_downloader_get_type ())
#define BOXES_DOWNLOADER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), BOXES_TYPE_DOWNLOADER, BoxesDownloader))
#define BOXES_DOWNLOADER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), BOXES_TYPE_DOWNLOADER, BoxesDownloaderClass))
#define BOXES_IS_DOWNLOADER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), BOXES_TYPE_DOWNLOADER))
#define BOXES_IS_DOWNLOADER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), BOXES_TYPE_DOWNLOADER))
#define BOXES_DOWNLOADER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), BOXES_TYPE_DOWNLOADER, BoxesDownloaderClass))

typedef struct _BoxesDownloader BoxesDownloader;
typedef struct _BoxesDownloaderClass BoxesDownloaderClass;
typedef struct _BoxesDownloaderPrivate BoxesDownloaderPrivate;
#define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL)))
#define _boxes_download_unref0(var) ((var == NULL) ? NULL : (var = (boxes_download_unref (var), NULL)))
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
typedef struct _BoxesDownloaderDownloadData BoxesDownloaderDownloadData;
typedef struct _Block79Data Block79Data;
typedef struct _BoxesDownloaderDownloadFromHttpData BoxesDownloaderDownloadFromHttpData;
typedef struct _BoxesDownloaderFetchOsLogoData BoxesDownloaderFetchOsLogoData;
typedef struct _Block80Data Block80Data;
typedef struct _BoxesDownloaderAwaitDownloadData BoxesDownloaderAwaitDownloadData;

struct _BoxesDownload {
	GTypeInstance parent_instance;
	volatile int ref_count;
	BoxesDownloadPrivate * priv;
	gchar* uri;
	GFile* cached_file;
	BoxesActivityProgress* progress;
};

struct _BoxesDownloadClass {
	GTypeClass parent_class;
	void (*finalize) (BoxesDownload *self);
};

struct _BoxesParamSpecDownload {
	GParamSpec parent_instance;
};

struct _BoxesDownloader {
	GObject parent_instance;
	BoxesDownloaderPrivate * priv;
};

struct _BoxesDownloaderClass {
	GObjectClass parent_class;
};

struct _BoxesDownloaderPrivate {
	SoupSessionAsync* session;
	GHashTable* downloads;
};

struct _BoxesDownloaderDownloadData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	BoxesDownloader* self;
	GFile* remote_file;
	gchar* cached_path;
	BoxesActivityProgress* progress;
	GFile* result;
	gchar* uri;
	GFile* _tmp0_;
	gchar* _tmp1_;
	BoxesDownload* download;
	GHashTable* _tmp2_;
	const gchar* _tmp3_;
	gconstpointer _tmp4_;
	BoxesDownload* _tmp5_;
	BoxesDownload* _tmp6_;
	GFile* _tmp7_;
	BoxesDownload* _tmp8_;
	const gchar* _tmp9_;
	BoxesActivityProgress* _tmp10_;
	GFile* _tmp11_;
	GFile* cached_file;
	const gchar* _tmp12_;
	GFile* _tmp13_;
	GFile* _tmp14_;
	gboolean _tmp15_;
	const gchar* _tmp16_;
	const gchar* _tmp17_;
	const gchar* _tmp18_;
	const gchar* _tmp19_;
	GFile* _tmp20_;
	BoxesActivityProgress* _tmp21_;
	BoxesDownload* _tmp22_;
	GHashTable* _tmp23_;
	const gchar* _tmp24_;
	gchar* _tmp25_;
	BoxesDownload* _tmp26_;
	BoxesDownload* _tmp27_;
	gboolean _tmp28_;
	GFile* _tmp29_;
	gboolean _tmp30_;
	GFile* _tmp31_;
	gboolean _tmp32_;
	gboolean _tmp33_;
	BoxesDownload* _tmp34_;
	GFile* _tmp35_;
	GFile* _tmp36_;
	GError* _error_;
	BoxesDownload* _tmp37_;
	GError* _tmp38_;
	GError* _tmp39_;
	GError* _tmp40_;
	GHashTable* _tmp41_;
	const gchar* _tmp42_;
	const gchar* _tmp43_;
	const gchar* _tmp44_;
	BoxesDownload* _tmp45_;
	GError * _inner_error_;
};

struct _Block79Data {
	int _ref_count_;
	BoxesDownloader * self;
	SoupMessage* msg;
	gint64 total_num_bytes;
	gint64 current_num_bytes;
	BoxesDownload* download;
	gpointer _async_data_;
};

struct _BoxesDownloaderDownloadFromHttpData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	BoxesDownloader* self;
	BoxesDownload* download;
	Block79Data* _data79_;
	BoxesDownload* _tmp0_;
	BoxesDownload* _tmp1_;
	const gchar* _tmp2_;
	SoupMessage* _tmp3_;
	SoupAddress* address;
	SoupMessage* _tmp4_;
	SoupAddress* _tmp5_;
	SoupAddress* _tmp6_;
	GNetworkAddress* connectable;
	SoupAddress* _tmp7_;
	const gchar* _tmp8_;
	const gchar* _tmp9_;
	SoupAddress* _tmp10_;
	gint _tmp11_;
	gint _tmp12_;
	GNetworkAddress* _tmp13_;
	GNetworkMonitor* network_monitor;
	GNetworkMonitor* _tmp14_;
	GNetworkMonitor* _tmp15_;
	gboolean _tmp16_;
	GNetworkMonitor* _tmp17_;
	GNetworkAddress* _tmp18_;
	gboolean _tmp19_;
	SoupAddress* _tmp20_;
	const gchar* _tmp21_;
	const gchar* _tmp22_;
	SoupAddress* _tmp23_;
	gint _tmp24_;
	gint _tmp25_;
	GError* _tmp26_;
	SoupMessage* _tmp27_;
	SoupMessage* _tmp28_;
	SoupSessionAsync* _tmp29_;
	SoupMessage* _tmp30_;
	SoupMessage* _tmp31_;
	SoupMessage* _tmp32_;
	guint _tmp33_;
	guint _tmp34_;
	SoupMessage* _tmp35_;
	gchar* _tmp36_;
	gchar* _tmp37_;
	gchar* _tmp38_;
	GError* _tmp39_;
	GError* _tmp40_;
	BoxesDownload* _tmp41_;
	GFile* _tmp42_;
	SoupMessage* _tmp43_;
	SoupMessageBody* _tmp44_;
	guint8* _tmp45_;
	gint _tmp45__length1;
	GError * _inner_error_;
};

struct _BoxesDownloaderFetchOsLogoData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	GtkImage* image;
	OsinfoOs* os;
	gint size;
	gchar* logo_url;
	OsinfoOs* _tmp0_;
	gchar* _tmp1_;
	const gchar* _tmp2_;
	OsinfoOs* _tmp3_;
	const gchar* _tmp4_;
	const gchar* _tmp5_;
	const gchar* _tmp6_;
	GFile* remote_file;
	const gchar* _tmp7_;
	GFile* _tmp8_;
	gchar* cached_path;
	GFile* _tmp9_;
	gchar* _tmp10_;
	gchar* _tmp11_;
	gchar* _tmp12_;
	gchar* _tmp13_;
	GFile* cached_file;
	BoxesDownloader* _tmp14_;
	BoxesDownloader* _tmp15_;
	GFile* _tmp16_;
	const gchar* _tmp17_;
	BoxesActivityProgress* _tmp18_;
	BoxesActivityProgress* _tmp19_;
	GFile* _tmp20_;
	GFile* _tmp21_;
	GdkPixbuf* pixbuf;
	GFile* _tmp22_;
	gchar* _tmp23_;
	gchar* _tmp24_;
	gint _tmp25_;
	gint _tmp26_;
	GdkPixbuf* _tmp27_;
	GdkPixbuf* _tmp28_;
	GtkImage* _tmp29_;
	GdkPixbuf* _tmp30_;
	GError* _error_;
	const gchar* _tmp31_;
	GError* _tmp32_;
	const gchar* _tmp33_;
	GError * _inner_error_;
};

struct _Block80Data {
	int _ref_count_;
	BoxesDownloader * self;
	GFile* downloaded_file;
	GError* download_error;
	GSourceFunc callback;
	gpointer callback_target;
	GDestroyNotify callback_target_destroy_notify;
	BoxesDownload* download;
	gpointer _async_data_;
};

struct _BoxesDownloaderAwaitDownloadData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	BoxesDownloader* self;
	BoxesDownload* download;
	gchar* cached_path;
	BoxesActivityProgress* progress;
	GFile* result;
	Block80Data* _data80_;
	BoxesDownload* _tmp0_;
	BoxesDownload* _tmp1_;
	BoxesActivityProgress* _tmp2_;
	BoxesActivityProgress* _tmp3_;
	gulong downloaded_id;
	gulong _tmp4_;
	gulong downloaded_failed_id;
	gulong _tmp5_;
	BoxesDownload* _tmp6_;
	const gchar* _tmp7_;
	BoxesDownload* _tmp8_;
	const gchar* _tmp9_;
	GError* _tmp10_;
	GFile* cached_file;
	gchar* _tmp11_;
	gchar* _tmp12_;
	const gchar* _tmp13_;
	gboolean _tmp14_;
	const gchar* _tmp15_;
	GFile* _tmp16_;
	GFile* _tmp17_;
	GFile* _tmp18_;
	GError * _inner_error_;
};


static gpointer boxes_download_parent_class = NULL;
static gpointer boxes_downloader_parent_class = NULL;
static BoxesDownloader* boxes_downloader_downloader;
static BoxesDownloader* boxes_downloader_downloader = NULL;

gpointer boxes_download_ref (gpointer instance);
void boxes_download_unref (gpointer instance);
GParamSpec* boxes_param_spec_download (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void boxes_value_set_download (GValue* value, gpointer v_object);
void boxes_value_take_download (GValue* value, gpointer v_object);
gpointer boxes_value_get_download (const GValue* value);
GType boxes_download_get_type (void) G_GNUC_CONST;
enum  {
	BOXES_DOWNLOAD_DUMMY_PROPERTY
};
BoxesDownload* boxes_download_new (const gchar* uri, GFile* cached_file, BoxesActivityProgress* progress);
BoxesDownload* boxes_download_construct (GType object_type, const gchar* uri, GFile* cached_file, BoxesActivityProgress* progress);
static void boxes_download_finalize (BoxesDownload* obj);
GType boxes_downloader_get_type (void) G_GNUC_CONST;
#define BOXES_DOWNLOADER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), BOXES_TYPE_DOWNLOADER, BoxesDownloaderPrivate))
enum  {
	BOXES_DOWNLOADER_DUMMY_PROPERTY
};
BoxesDownloader* boxes_downloader_get_instance (void);
static BoxesDownloader* boxes_downloader_new (void);
static BoxesDownloader* boxes_downloader_construct (GType object_type);
static gchar* boxes_downloader_fetch_os_logo_url (OsinfoOs* os);
static void _g_free0_ (gpointer var);
static void _boxes_download_unref0_ (gpointer var);
static void boxes_downloader_download_data_free (gpointer _data);
void boxes_downloader_download (BoxesDownloader* self, GFile* remote_file, const gchar* cached_path, BoxesActivityProgress* progress, GAsyncReadyCallback _callback_, gpointer _user_data_);
GFile* boxes_downloader_download_finish (BoxesDownloader* self, GAsyncResult* _res_, GError** error);
static gboolean boxes_downloader_download_co (BoxesDownloaderDownloadData* _data_);
static void boxes_downloader_await_download (BoxesDownloader* self, BoxesDownload* download, const gchar* cached_path, BoxesActivityProgress* progress, GAsyncReadyCallback _callback_, gpointer _user_data_);
static GFile* boxes_downloader_await_download_finish (BoxesDownloader* self, GAsyncResult* _res_, GError** error);
static void boxes_downloader_download_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void boxes_downloader_download_from_http (BoxesDownloader* self, BoxesDownload* download, GAsyncReadyCallback _callback_, gpointer _user_data_);
static void boxes_downloader_download_from_http_finish (BoxesDownloader* self, GAsyncResult* _res_, GError** error);
void boxes_copy_file (GFile* src_file, GFile* dest_file, GCancellable* cancellable, GAsyncReadyCallback _callback_, gpointer _user_data_);
void boxes_copy_file_finish (GAsyncResult* _res_, GError** error);
static void boxes_downloader_download_from_http_data_free (gpointer _data);
static gboolean boxes_downloader_download_from_http_co (BoxesDownloaderDownloadFromHttpData* _data_);
static Block79Data* block79_data_ref (Block79Data* _data79_);
static void block79_data_unref (void * _userdata_);
static void boxes_downloader_download_from_http_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void __lambda54_ (Block79Data* _data79_);
static void ___lambda54__soup_message_got_headers (SoupMessage* _sender, gpointer self);
static void __lambda55_ (Block79Data* _data79_, SoupMessage* msg, SoupBuffer* chunk);
static void ___lambda55__soup_message_got_chunk (SoupMessage* _sender, SoupBuffer* chunk, gpointer self);
static void __lambda56_ (Block79Data* _data79_, SoupSession* session, SoupMessage* msg);
static void ___lambda56__soup_session_callback (SoupSession* session, SoupMessage* msg, gpointer self);
static void boxes_downloader_fetch_os_logo_data_free (gpointer _data);
void boxes_downloader_fetch_os_logo (GtkImage* image, OsinfoOs* os, gint size, GAsyncReadyCallback _callback_, gpointer _user_data_);
void boxes_downloader_fetch_os_logo_finish (GAsyncResult* _res_);
static gboolean boxes_downloader_fetch_os_logo_co (BoxesDownloaderFetchOsLogoData* _data_);
static void boxes_downloader_fetch_os_logo_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void boxes_downloader_await_download_data_free (gpointer _data);
static gboolean boxes_downloader_await_download_co (BoxesDownloaderAwaitDownloadData* _data_);
static Block80Data* block80_data_ref (Block80Data* _data80_);
static void block80_data_unref (void * _userdata_);
static gboolean _boxes_downloader_await_download_co_gsource_func (gpointer self);
static void __lambda52_ (Block80Data* _data80_, BoxesDownloader* downloader, BoxesDownload* downloaded);
static void ___lambda52__boxes_downloader_downloaded (BoxesDownloader* _sender, BoxesDownload* download, gpointer self);
static void __lambda53_ (Block80Data* _data80_, BoxesDownloader* downloader, BoxesDownload* failed_download, GError* _error_);
static void ___lambda53__boxes_downloader_download_failed (BoxesDownloader* _sender, BoxesDownload* download, GError* _error_, gpointer self);
static void boxes_downloader_await_download_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void g_cclosure_user_marshal_VOID__BOXES_DOWNLOAD (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data);
static void g_cclosure_user_marshal_VOID__BOXES_DOWNLOAD_POINTER (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data);
static void boxes_downloader_finalize (GObject* obj);


static gpointer _g_object_ref0 (gpointer self) {
#line 10 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return self ? g_object_ref (self) : NULL;
#line 396 "downloader.c"
}


BoxesDownload* boxes_download_construct (GType object_type, const gchar* uri, GFile* cached_file, BoxesActivityProgress* progress) {
	BoxesDownload* self = NULL;
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
	GFile* _tmp2_ = NULL;
	GFile* _tmp3_ = NULL;
	BoxesActivityProgress* _tmp4_ = NULL;
	BoxesActivityProgress* _tmp5_ = NULL;
#line 8 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_val_if_fail (uri != NULL, NULL);
#line 8 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_val_if_fail (cached_file != NULL, NULL);
#line 8 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_val_if_fail (progress != NULL, NULL);
#line 8 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self = (BoxesDownload*) g_type_create_instance (object_type);
#line 9 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = uri;
#line 9 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = g_strdup (_tmp0_);
#line 9 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (self->uri);
#line 9 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self->uri = _tmp1_;
#line 10 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = cached_file;
#line 10 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp3_ = _g_object_ref0 (_tmp2_);
#line 10 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (self->cached_file);
#line 10 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self->cached_file = _tmp3_;
#line 11 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp4_ = progress;
#line 11 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp5_ = _g_object_ref0 (_tmp4_);
#line 11 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (self->progress);
#line 11 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self->progress = _tmp5_;
#line 8 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return self;
#line 442 "downloader.c"
}


BoxesDownload* boxes_download_new (const gchar* uri, GFile* cached_file, BoxesActivityProgress* progress) {
#line 8 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return boxes_download_construct (BOXES_TYPE_DOWNLOAD, uri, cached_file, progress);
#line 449 "downloader.c"
}


static void boxes_value_download_init (GValue* value) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	value->data[0].v_pointer = NULL;
#line 456 "downloader.c"
}


static void boxes_value_download_free_value (GValue* value) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (value->data[0].v_pointer) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		boxes_download_unref (value->data[0].v_pointer);
#line 465 "downloader.c"
	}
}


static void boxes_value_download_copy_value (const GValue* src_value, GValue* dest_value) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (src_value->data[0].v_pointer) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		dest_value->data[0].v_pointer = boxes_download_ref (src_value->data[0].v_pointer);
#line 475 "downloader.c"
	} else {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		dest_value->data[0].v_pointer = NULL;
#line 479 "downloader.c"
	}
}


static gpointer boxes_value_download_peek_pointer (const GValue* value) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return value->data[0].v_pointer;
#line 487 "downloader.c"
}


static gchar* boxes_value_download_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (collect_values[0].v_pointer) {
#line 494 "downloader.c"
		BoxesDownload* object;
		object = collect_values[0].v_pointer;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (object->parent_instance.g_class == NULL) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 501 "downloader.c"
		} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 505 "downloader.c"
		}
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		value->data[0].v_pointer = boxes_download_ref (object);
#line 509 "downloader.c"
	} else {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		value->data[0].v_pointer = NULL;
#line 513 "downloader.c"
	}
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return NULL;
#line 517 "downloader.c"
}


static gchar* boxes_value_download_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
	BoxesDownload** object_p;
	object_p = collect_values[0].v_pointer;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (!object_p) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
#line 528 "downloader.c"
	}
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (!value->data[0].v_pointer) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		*object_p = NULL;
#line 534 "downloader.c"
	} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		*object_p = value->data[0].v_pointer;
#line 538 "downloader.c"
	} else {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		*object_p = boxes_download_ref (value->data[0].v_pointer);
#line 542 "downloader.c"
	}
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return NULL;
#line 546 "downloader.c"
}


GParamSpec* boxes_param_spec_download (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
	BoxesParamSpecDownload* spec;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_val_if_fail (g_type_is_a (object_type, BOXES_TYPE_DOWNLOAD), NULL);
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags);
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	G_PARAM_SPEC (spec)->value_type = object_type;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return G_PARAM_SPEC (spec);
#line 560 "downloader.c"
}


gpointer boxes_value_get_download (const GValue* value) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, BOXES_TYPE_DOWNLOAD), NULL);
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return value->data[0].v_pointer;
#line 569 "downloader.c"
}


void boxes_value_set_download (GValue* value, gpointer v_object) {
	BoxesDownload* old;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, BOXES_TYPE_DOWNLOAD));
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	old = value->data[0].v_pointer;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (v_object) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, BOXES_TYPE_DOWNLOAD));
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		value->data[0].v_pointer = v_object;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		boxes_download_ref (value->data[0].v_pointer);
#line 589 "downloader.c"
	} else {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		value->data[0].v_pointer = NULL;
#line 593 "downloader.c"
	}
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (old) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		boxes_download_unref (old);
#line 599 "downloader.c"
	}
}


void boxes_value_take_download (GValue* value, gpointer v_object) {
	BoxesDownload* old;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, BOXES_TYPE_DOWNLOAD));
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	old = value->data[0].v_pointer;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (v_object) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, BOXES_TYPE_DOWNLOAD));
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		value->data[0].v_pointer = v_object;
#line 618 "downloader.c"
	} else {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		value->data[0].v_pointer = NULL;
#line 622 "downloader.c"
	}
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (old) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		boxes_download_unref (old);
#line 628 "downloader.c"
	}
}


static void boxes_download_class_init (BoxesDownloadClass * klass) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_download_parent_class = g_type_class_peek_parent (klass);
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	BOXES_DOWNLOAD_CLASS (klass)->finalize = boxes_download_finalize;
#line 638 "downloader.c"
}


static void boxes_download_instance_init (BoxesDownload * self) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self->ref_count = 1;
#line 645 "downloader.c"
}


static void boxes_download_finalize (BoxesDownload* obj) {
	BoxesDownload * self;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, BOXES_TYPE_DOWNLOAD, BoxesDownload);
#line 4 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (self->uri);
#line 5 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (self->cached_file);
#line 6 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (self->progress);
#line 659 "downloader.c"
}


GType boxes_download_get_type (void) {
	static volatile gsize boxes_download_type_id__volatile = 0;
	if (g_once_init_enter (&boxes_download_type_id__volatile)) {
		static const GTypeValueTable g_define_type_value_table = { boxes_value_download_init, boxes_value_download_free_value, boxes_value_download_copy_value, boxes_value_download_peek_pointer, "p", boxes_value_download_collect_value, "p", boxes_value_download_lcopy_value };
		static const GTypeInfo g_define_type_info = { sizeof (BoxesDownloadClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) boxes_download_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (BoxesDownload), 0, (GInstanceInitFunc) boxes_download_instance_init, &g_define_type_value_table };
		static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) };
		GType boxes_download_type_id;
		boxes_download_type_id = g_type_register_fundamental (g_type_fundamental_next (), "BoxesDownload", &g_define_type_info, &g_define_type_fundamental_info, 0);
		g_once_init_leave (&boxes_download_type_id__volatile, boxes_download_type_id);
	}
	return boxes_download_type_id__volatile;
}


gpointer boxes_download_ref (gpointer instance) {
	BoxesDownload* self;
	self = instance;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_atomic_int_inc (&self->ref_count);
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return instance;
#line 684 "downloader.c"
}


void boxes_download_unref (gpointer instance) {
	BoxesDownload* self;
	self = instance;
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (g_atomic_int_dec_and_test (&self->ref_count)) {
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		BOXES_DOWNLOAD_GET_CLASS (self)->finalize (self);
#line 3 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_type_free_instance ((GTypeInstance *) self);
#line 697 "downloader.c"
	}
}


BoxesDownloader* boxes_downloader_get_instance (void) {
	BoxesDownloader* result = NULL;
	BoxesDownloader* _tmp0_ = NULL;
	BoxesDownloader* _tmp2_ = NULL;
	BoxesDownloader* _tmp3_ = NULL;
#line 25 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = boxes_downloader_downloader;
#line 25 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_tmp0_ == NULL) {
#line 711 "downloader.c"
		BoxesDownloader* _tmp1_ = NULL;
#line 26 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp1_ = boxes_downloader_new ();
#line 26 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (boxes_downloader_downloader);
#line 26 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		boxes_downloader_downloader = _tmp1_;
#line 719 "downloader.c"
	}
#line 28 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = boxes_downloader_downloader;
#line 28 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp3_ = _g_object_ref0 (_tmp2_);
#line 28 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	result = _tmp3_;
#line 28 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return result;
#line 729 "downloader.c"
}


static gchar* boxes_downloader_fetch_os_logo_url (OsinfoOs* os) {
	gchar* result = NULL;
	OsinfoOs* _tmp0_ = NULL;
	const gchar* _tmp1_ = NULL;
	const gchar* _tmp2_ = NULL;
	gchar* logo_url = NULL;
	OsinfoProductList* derived = NULL;
	OsinfoOs* _tmp7_ = NULL;
	OsinfoProductList* _tmp8_ = NULL;
#line 31 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_val_if_fail (os != NULL, NULL);
#line 32 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = os;
#line 32 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = osinfo_product_get_logo ((OsinfoProduct*) _tmp0_);
#line 32 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = _tmp1_;
#line 32 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_tmp2_ != NULL) {
#line 752 "downloader.c"
		OsinfoOs* _tmp3_ = NULL;
		const gchar* _tmp4_ = NULL;
		const gchar* _tmp5_ = NULL;
		gchar* _tmp6_ = NULL;
#line 33 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp3_ = os;
#line 33 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp4_ = osinfo_product_get_logo ((OsinfoProduct*) _tmp3_);
#line 33 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp5_ = _tmp4_;
#line 33 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp6_ = g_strdup (_tmp5_);
#line 33 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		result = _tmp6_;
#line 33 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return result;
#line 769 "downloader.c"
	}
#line 35 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	logo_url = NULL;
#line 36 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp7_ = os;
#line 36 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp8_ = osinfo_product_get_related ((OsinfoProduct*) _tmp7_, OSINFO_PRODUCT_RELATIONSHIP_DERIVES_FROM);
#line 36 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	derived = _tmp8_;
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	while (TRUE) {
#line 781 "downloader.c"
		gboolean _tmp9_ = FALSE;
		OsinfoProductList* _tmp10_ = NULL;
		gint _tmp11_ = 0;
		gboolean _tmp13_ = FALSE;
		OsinfoOs* parent = NULL;
		OsinfoProductList* _tmp14_ = NULL;
		OsinfoEntity* _tmp15_ = NULL;
		OsinfoOs* _tmp16_ = NULL;
		OsinfoOs* _tmp17_ = NULL;
		const gchar* _tmp18_ = NULL;
		const gchar* _tmp19_ = NULL;
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp10_ = derived;
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp11_ = osinfo_list_get_length ((OsinfoList*) _tmp10_);
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_tmp11_ > 0) {
#line 799 "downloader.c"
			const gchar* _tmp12_ = NULL;
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_tmp12_ = logo_url;
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_tmp9_ = _tmp12_ == NULL;
#line 805 "downloader.c"
		} else {
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_tmp9_ = FALSE;
#line 809 "downloader.c"
		}
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp13_ = _tmp9_;
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (!_tmp13_) {
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			break;
#line 817 "downloader.c"
		}
#line 39 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp14_ = derived;
#line 39 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp15_ = osinfo_list_get_nth ((OsinfoList*) _tmp14_, 0);
#line 39 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp16_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp15_, osinfo_os_get_type ()) ? ((OsinfoOs*) _tmp15_) : NULL);
#line 39 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		parent = _tmp16_;
#line 41 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp17_ = parent;
#line 41 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp18_ = osinfo_product_get_logo ((OsinfoProduct*) _tmp17_);
#line 41 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_tmp19_ = _tmp18_;
#line 41 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_tmp19_ != NULL) {
#line 835 "downloader.c"
			OsinfoOs* _tmp20_ = NULL;
			const gchar* _tmp21_ = NULL;
			const gchar* _tmp22_ = NULL;
			gchar* _tmp23_ = NULL;
#line 42 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_tmp20_ = parent;
#line 42 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_tmp21_ = osinfo_product_get_logo ((OsinfoProduct*) _tmp20_);
#line 42 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_tmp22_ = _tmp21_;
#line 42 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_tmp23_ = g_strdup (_tmp22_);
#line 42 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_g_free0 (logo_url);
#line 42 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			logo_url = _tmp23_;
#line 852 "downloader.c"
		} else {
			OsinfoOs* _tmp24_ = NULL;
			OsinfoProductList* _tmp25_ = NULL;
#line 44 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_tmp24_ = parent;
#line 44 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_tmp25_ = osinfo_product_get_related ((OsinfoProduct*) _tmp24_, OSINFO_PRODUCT_RELATIONSHIP_DERIVES_FROM);
#line 44 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_g_object_unref0 (derived);
#line 44 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			derived = _tmp25_;
#line 864 "downloader.c"
		}
#line 37 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (parent);
#line 868 "downloader.c"
	}
#line 47 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	result = logo_url;
#line 47 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (derived);
#line 47 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return result;
#line 876 "downloader.c"
}


static void _g_free0_ (gpointer var) {
#line 51 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	var = (g_free (var), NULL);
#line 883 "downloader.c"
}


static void _boxes_download_unref0_ (gpointer var) {
#line 51 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	(var == NULL) ? NULL : (var = (boxes_download_unref (var), NULL));
#line 890 "downloader.c"
}


static BoxesDownloader* boxes_downloader_construct (GType object_type) {
	BoxesDownloader * self = NULL;
	GHashFunc _tmp0_ = NULL;
	GEqualFunc _tmp1_ = NULL;
	GHashTable* _tmp2_ = NULL;
	SoupSessionAsync* _tmp3_ = NULL;
	SoupSessionAsync* _tmp4_ = NULL;
#line 50 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self = (BoxesDownloader*) g_object_new (object_type, NULL);
#line 51 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = g_str_hash;
#line 51 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = g_str_equal;
#line 51 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = g_hash_table_new_full (_tmp0_, _tmp1_, _g_free0_, _boxes_download_unref0_);
#line 51 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_hash_table_unref0 (self->priv->downloads);
#line 51 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self->priv->downloads = _tmp2_;
#line 53 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp3_ = (SoupSessionAsync*) soup_session_async_new ();
#line 53 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (self->priv->session);
#line 53 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self->priv->session = _tmp3_;
#line 54 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp4_ = self->priv->session;
#line 54 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	soup_session_add_feature_by_type ((SoupSession*) _tmp4_, soup_proxy_resolver_default_get_type ());
#line 50 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return self;
#line 925 "downloader.c"
}


static BoxesDownloader* boxes_downloader_new (void) {
#line 50 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return boxes_downloader_construct (BOXES_TYPE_DOWNLOADER);
#line 932 "downloader.c"
}


static void boxes_downloader_download_data_free (gpointer _data) {
	BoxesDownloaderDownloadData* _data_;
	_data_ = _data;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->remote_file);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->cached_path);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->progress);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->result);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->self);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_slice_free (BoxesDownloaderDownloadData, _data_);
#line 951 "downloader.c"
}


void boxes_downloader_download (BoxesDownloader* self, GFile* remote_file, const gchar* cached_path, BoxesActivityProgress* progress, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	BoxesDownloaderDownloadData* _data_;
	BoxesDownloader* _tmp0_ = NULL;
	GFile* _tmp1_ = NULL;
	GFile* _tmp2_ = NULL;
	const gchar* _tmp3_ = NULL;
	gchar* _tmp4_ = NULL;
	BoxesActivityProgress* _tmp5_ = NULL;
	BoxesActivityProgress* _tmp6_ = NULL;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = g_slice_new0 (BoxesDownloaderDownloadData);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, boxes_downloader_download);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, boxes_downloader_download_data_free);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = _g_object_ref0 (self);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->self = _tmp0_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = remote_file;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = _g_object_ref0 (_tmp1_);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->remote_file);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->remote_file = _tmp2_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp3_ = cached_path;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp4_ = g_strdup (_tmp3_);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->cached_path);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->cached_path = _tmp4_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp5_ = progress;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp6_ = _g_object_ref0 (_tmp5_);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->progress);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->progress = _tmp6_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_download_co (_data_);
#line 1000 "downloader.c"
}


GFile* boxes_downloader_download_finish (BoxesDownloader* self, GAsyncResult* _res_, GError** error) {
	GFile* result;
	BoxesDownloaderDownloadData* _data_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (_res_), error)) {
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return NULL;
#line 1011 "downloader.c"
	}
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	result = _data_->result;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->result = NULL;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return result;
#line 1021 "downloader.c"
}


static gpointer _boxes_download_ref0 (gpointer self) {
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return self ? boxes_download_ref (self) : NULL;
#line 1028 "downloader.c"
}


static void boxes_downloader_download_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	BoxesDownloaderDownloadData* _data_;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = _user_data_;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_source_object_ = source_object;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_res_ = _res_;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_download_co (_data_);
#line 1042 "downloader.c"
}


static gpointer _g_error_copy0 (gpointer self) {
#line 84 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return self ? g_error_copy (self) : NULL;
#line 1049 "downloader.c"
}


static gboolean boxes_downloader_download_co (BoxesDownloaderDownloadData* _data_) {
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	switch (_data_->_state_) {
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 0:
#line 1058 "downloader.c"
		goto _state_0;
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 1:
#line 1062 "downloader.c"
		goto _state_1;
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 2:
#line 1066 "downloader.c"
		goto _state_2;
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 3:
#line 1070 "downloader.c"
		goto _state_3;
		default:
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_assert_not_reached ();
#line 1075 "downloader.c"
	}
	_state_0:
#line 60 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp0_ = NULL;
#line 60 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp0_ = _data_->remote_file;
#line 60 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp1_ = NULL;
#line 60 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp1_ = g_file_get_uri (_data_->_tmp0_);
#line 60 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->uri = _data_->_tmp1_;
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp2_ = NULL;
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp2_ = _data_->self->priv->downloads;
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp3_ = NULL;
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp3_ = _data_->uri;
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp4_ = NULL;
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp4_ = g_hash_table_lookup (_data_->_tmp2_, _data_->_tmp3_);
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp5_ = NULL;
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp5_ = _boxes_download_ref0 ((BoxesDownload*) _data_->_tmp4_);
#line 61 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->download = _data_->_tmp5_;
#line 62 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp6_ = NULL;
#line 62 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp6_ = _data_->download;
#line 62 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_tmp6_ != NULL) {
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp8_ = NULL;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp8_ = _data_->download;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp9_ = NULL;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp9_ = _data_->cached_path;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp10_ = NULL;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp10_ = _data_->progress;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_state_ = 1;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		boxes_downloader_await_download (_data_->self, _data_->_tmp8_, _data_->_tmp9_, _data_->_tmp10_, boxes_downloader_download_ready, _data_);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 1130 "downloader.c"
		_state_1:
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp11_ = NULL;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp11_ = boxes_downloader_await_download_finish (_data_->self, _data_->_res_, &_data_->_inner_error_);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp7_ = _data_->_tmp11_;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_inner_error_ != NULL) {
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_error_free (_data_->_inner_error_);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_boxes_download_unref0 (_data_->download);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_g_free0 (_data_->uri);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			if (_data_->_state_ == 0) {
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
				g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 1152 "downloader.c"
			} else {
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
				g_simple_async_result_complete (_data_->_async_result);
#line 1156 "downloader.c"
			}
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_object_unref (_data_->_async_result);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			return FALSE;
#line 1162 "downloader.c"
		}
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->result = _data_->_tmp7_;
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_boxes_download_unref0 (_data_->download);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_free0 (_data_->uri);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_state_ == 0) {
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 1174 "downloader.c"
		} else {
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete (_data_->_async_result);
#line 1178 "downloader.c"
		}
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_unref (_data_->_async_result);
#line 64 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 1184 "downloader.c"
	}
#line 66 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp12_ = NULL;
#line 66 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp12_ = _data_->cached_path;
#line 66 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp13_ = NULL;
#line 66 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp13_ = g_file_new_for_path (_data_->_tmp12_);
#line 66 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->cached_file = _data_->_tmp13_;
#line 67 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp14_ = NULL;
#line 67 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp14_ = _data_->cached_file;
#line 67 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp15_ = FALSE;
#line 67 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp15_ = g_file_query_exists (_data_->_tmp14_, NULL);
#line 67 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_tmp15_) {
#line 68 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp16_ = NULL;
#line 68 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp16_ = _data_->uri;
#line 68 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp17_ = NULL;
#line 68 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp17_ = _data_->cached_path;
#line 68 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_debug ("downloader.vala:68: '%s' already available locally at '%s'. Not downlo" \
"ading.", _data_->_tmp16_, _data_->_tmp17_);
#line 69 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->result = _data_->cached_file;
#line 69 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_boxes_download_unref0 (_data_->download);
#line 69 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_free0 (_data_->uri);
#line 69 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_state_ == 0) {
#line 69 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 1226 "downloader.c"
		} else {
#line 69 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete (_data_->_async_result);
#line 1230 "downloader.c"
		}
#line 69 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_unref (_data_->_async_result);
#line 69 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 1236 "downloader.c"
	}
#line 72 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp18_ = NULL;
#line 72 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp18_ = _data_->uri;
#line 72 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_debug ("downloader.vala:72: Downloading '%s'...", _data_->_tmp18_);
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp19_ = NULL;
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp19_ = _data_->uri;
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp20_ = NULL;
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp20_ = _data_->cached_file;
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp21_ = NULL;
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp21_ = _data_->progress;
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp22_ = NULL;
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp22_ = boxes_download_new (_data_->_tmp19_, _data_->_tmp20_, _data_->_tmp21_);
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_boxes_download_unref0 (_data_->download);
#line 73 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->download = _data_->_tmp22_;
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp23_ = NULL;
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp23_ = _data_->self->priv->downloads;
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp24_ = NULL;
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp24_ = _data_->uri;
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp25_ = NULL;
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp25_ = g_strdup (_data_->_tmp24_);
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp26_ = NULL;
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp26_ = _data_->download;
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp27_ = NULL;
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp27_ = _boxes_download_ref0 (_data_->_tmp26_);
#line 74 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_hash_table_insert (_data_->_tmp23_, _data_->_tmp25_, _data_->_tmp27_);
#line 1286 "downloader.c"
	{
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp29_ = NULL;
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp29_ = _data_->remote_file;
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp30_ = FALSE;
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp30_ = g_file_has_uri_scheme (_data_->_tmp29_, "http");
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_tmp30_) {
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp28_ = TRUE;
#line 1300 "downloader.c"
		} else {
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp31_ = NULL;
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp31_ = _data_->remote_file;
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp32_ = FALSE;
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp32_ = g_file_has_uri_scheme (_data_->_tmp31_, "https");
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp28_ = _data_->_tmp32_;
#line 1312 "downloader.c"
		}
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp33_ = FALSE;
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp33_ = _data_->_tmp28_;
#line 77 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_tmp33_) {
#line 78 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp34_ = NULL;
#line 78 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp34_ = _data_->download;
#line 78 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_state_ = 2;
#line 78 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			boxes_downloader_download_from_http (_data_->self, _data_->_tmp34_, boxes_downloader_download_ready, _data_);
#line 78 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			return FALSE;
#line 1330 "downloader.c"
			_state_2:
#line 78 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			boxes_downloader_download_from_http_finish (_data_->self, _data_->_res_, &_data_->_inner_error_);
#line 78 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			if (_data_->_inner_error_ != NULL) {
#line 1336 "downloader.c"
				goto __catch113_g_error;
			}
		} else {
#line 80 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp35_ = NULL;
#line 80 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp35_ = _data_->remote_file;
#line 80 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp36_ = NULL;
#line 80 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_tmp36_ = _data_->cached_file;
#line 80 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_state_ = 3;
#line 80 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			boxes_copy_file (_data_->_tmp35_, _data_->_tmp36_, NULL, boxes_downloader_download_ready, _data_);
#line 80 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			return FALSE;
#line 1354 "downloader.c"
			_state_3:
#line 80 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			boxes_copy_file_finish (_data_->_res_, &_data_->_inner_error_);
#line 80 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			if (_data_->_inner_error_ != NULL) {
#line 1360 "downloader.c"
				goto __catch113_g_error;
			}
		}
	}
	goto __finally113;
	__catch113_g_error:
	{
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_error_ = _data_->_inner_error_;
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_inner_error_ = NULL;
#line 82 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp37_ = NULL;
#line 82 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp37_ = _data_->download;
#line 82 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp38_ = NULL;
#line 82 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp38_ = _data_->_error_;
#line 82 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_signal_emit_by_name (_data_->self, "download-failed", _data_->_tmp37_, _data_->_tmp38_);
#line 84 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp39_ = NULL;
#line 84 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp39_ = _data_->_error_;
#line 84 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp40_ = NULL;
#line 84 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp40_ = _g_error_copy0 (_data_->_tmp39_);
#line 84 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_inner_error_ = _data_->_tmp40_;
#line 84 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_error_free0 (_data_->_error_);
#line 1394 "downloader.c"
		goto __finally113;
	}
	__finally113:
	{
#line 86 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp41_ = NULL;
#line 86 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp41_ = _data_->self->priv->downloads;
#line 86 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp42_ = NULL;
#line 86 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp42_ = _data_->uri;
#line 86 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_hash_table_remove (_data_->_tmp41_, _data_->_tmp42_);
#line 1409 "downloader.c"
	}
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_inner_error_ != NULL) {
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_error_free (_data_->_inner_error_);
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->cached_file);
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_boxes_download_unref0 (_data_->download);
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_free0 (_data_->uri);
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_state_ == 0) {
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 1427 "downloader.c"
		} else {
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete (_data_->_async_result);
#line 1431 "downloader.c"
		}
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_unref (_data_->_async_result);
#line 76 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 1437 "downloader.c"
	}
#line 89 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp43_ = NULL;
#line 89 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp43_ = _data_->uri;
#line 89 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp44_ = NULL;
#line 89 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp44_ = _data_->cached_path;
#line 89 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_debug ("downloader.vala:89: Downloaded '%s' and its now locally available at '" \
"%s'.", _data_->_tmp43_, _data_->_tmp44_);
#line 90 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp45_ = NULL;
#line 90 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp45_ = _data_->download;
#line 90 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_signal_emit_by_name (_data_->self, "downloaded", _data_->_tmp45_);
#line 92 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->result = _data_->cached_file;
#line 92 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_boxes_download_unref0 (_data_->download);
#line 92 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->uri);
#line 92 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_state_ == 0) {
#line 92 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 1465 "downloader.c"
	} else {
#line 92 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete (_data_->_async_result);
#line 1469 "downloader.c"
	}
#line 92 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_object_unref (_data_->_async_result);
#line 92 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->cached_file);
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_boxes_download_unref0 (_data_->download);
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->uri);
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_state_ == 0) {
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 1485 "downloader.c"
	} else {
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete (_data_->_async_result);
#line 1489 "downloader.c"
	}
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_object_unref (_data_->_async_result);
#line 57 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 1495 "downloader.c"
}


static void boxes_downloader_download_from_http_data_free (gpointer _data) {
	BoxesDownloaderDownloadFromHttpData* _data_;
	_data_ = _data;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->self);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_slice_free (BoxesDownloaderDownloadFromHttpData, _data_);
#line 1506 "downloader.c"
}


static void boxes_downloader_download_from_http (BoxesDownloader* self, BoxesDownload* download, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	BoxesDownloaderDownloadFromHttpData* _data_;
	BoxesDownloader* _tmp0_ = NULL;
	BoxesDownload* _tmp1_ = NULL;
	BoxesDownload* _tmp2_ = NULL;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = g_slice_new0 (BoxesDownloaderDownloadFromHttpData);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, boxes_downloader_download_from_http);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, boxes_downloader_download_from_http_data_free);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = _g_object_ref0 (self);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->self = _tmp0_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = download;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = _boxes_download_ref0 (_tmp1_);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_boxes_download_unref0 (_data_->download);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->download = _tmp2_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_download_from_http_co (_data_);
#line 1535 "downloader.c"
}


static void boxes_downloader_download_from_http_finish (BoxesDownloader* self, GAsyncResult* _res_, GError** error) {
	BoxesDownloaderDownloadFromHttpData* _data_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (_res_), error)) {
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return;
#line 1545 "downloader.c"
	}
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
#line 1549 "downloader.c"
}


static Block79Data* block79_data_ref (Block79Data* _data79_) {
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_atomic_int_inc (&_data79_->_ref_count_);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return _data79_;
#line 1558 "downloader.c"
}


static void block79_data_unref (void * _userdata_) {
	Block79Data* _data79_;
	_data79_ = (Block79Data*) _userdata_;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (g_atomic_int_dec_and_test (&_data79_->_ref_count_)) {
#line 1567 "downloader.c"
		BoxesDownloader * self;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		self = _data79_->self;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data79_->msg);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_boxes_download_unref0 (_data79_->download);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (self);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_slice_free (Block79Data, _data79_);
#line 1579 "downloader.c"
	}
}


static void boxes_downloader_download_from_http_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	BoxesDownloaderDownloadFromHttpData* _data_;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = _user_data_;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_source_object_ = source_object;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_res_ = _res_;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_download_from_http_co (_data_);
#line 1594 "downloader.c"
}


static void __lambda54_ (Block79Data* _data79_) {
	BoxesDownloader * self;
	SoupMessage* _tmp0_ = NULL;
	SoupMessageHeaders* _tmp1_ = NULL;
	gint64 _tmp2_ = 0LL;
#line 104 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self = _data79_->self;
#line 105 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = _data79_->msg;
#line 105 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = _tmp0_->response_headers;
#line 105 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = soup_message_headers_get_content_length (_tmp1_);
#line 105 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data79_->total_num_bytes = _tmp2_;
#line 1613 "downloader.c"
}


static void ___lambda54__soup_message_got_headers (SoupMessage* _sender, gpointer self) {
#line 104 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	__lambda54_ (self);
#line 1620 "downloader.c"
}


static void __lambda55_ (Block79Data* _data79_, SoupMessage* msg, SoupBuffer* chunk) {
	BoxesDownloader * self;
	gint64 _tmp0_ = 0LL;
	gint64 _tmp1_ = 0LL;
	SoupBuffer* _tmp2_ = NULL;
	gsize _tmp3_ = 0UL;
	BoxesDownload* _tmp4_ = NULL;
	BoxesActivityProgress* _tmp5_ = NULL;
	gint64 _tmp6_ = 0LL;
	gint64 _tmp7_ = 0LL;
#line 109 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self = _data79_->self;
#line 109 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (msg != NULL);
#line 109 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (chunk != NULL);
#line 110 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = _data79_->total_num_bytes;
#line 110 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_tmp0_ <= ((gint64) 0)) {
#line 111 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return;
#line 1646 "downloader.c"
	}
#line 113 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = _data79_->current_num_bytes;
#line 113 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = chunk;
#line 113 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp3_ = _tmp2_->length;
#line 113 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data79_->current_num_bytes = _tmp1_ + _tmp3_;
#line 114 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp4_ = _data79_->download;
#line 114 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp5_ = _tmp4_->progress;
#line 114 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp6_ = _data79_->current_num_bytes;
#line 114 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp7_ = _data79_->total_num_bytes;
#line 114 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_activity_progress_set_progress (_tmp5_, ((gdouble) _tmp6_) / _tmp7_);
#line 1666 "downloader.c"
}


static void ___lambda55__soup_message_got_chunk (SoupMessage* _sender, SoupBuffer* chunk, gpointer self) {
#line 109 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	__lambda55_ (self, _sender, chunk);
#line 1673 "downloader.c"
}


static void __lambda56_ (Block79Data* _data79_, SoupSession* session, SoupMessage* msg) {
	BoxesDownloader * self;
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self = _data79_->self;
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (session != NULL);
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (msg != NULL);
#line 118 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_download_from_http_co (_data79_->_async_data_);
#line 1687 "downloader.c"
}


static void ___lambda56__soup_session_callback (SoupSession* session, SoupMessage* msg, gpointer self) {
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	__lambda56_ (self, session, msg);
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	block79_data_unref (self);
#line 1696 "downloader.c"
}


static gboolean boxes_downloader_download_from_http_co (BoxesDownloaderDownloadFromHttpData* _data_) {
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	switch (_data_->_state_) {
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 0:
#line 1705 "downloader.c"
		goto _state_0;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 1:
#line 1709 "downloader.c"
		goto _state_1;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 2:
#line 1713 "downloader.c"
		goto _state_2;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 3:
#line 1717 "downloader.c"
		goto _state_3;
		default:
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_assert_not_reached ();
#line 1722 "downloader.c"
	}
	_state_0:
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data79_ = g_slice_new0 (Block79Data);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data79_->_ref_count_ = 1;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data79_->self = g_object_ref (_data_->self);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp0_ = NULL;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp0_ = _data_->download;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_boxes_download_unref0 (_data_->_data79_->download);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data79_->download = _data_->_tmp0_;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data79_->_async_data_ = _data_;
#line 96 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp1_ = NULL;
#line 96 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp1_ = _data_->_data79_->download;
#line 96 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp2_ = NULL;
#line 96 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp2_ = _data_->_tmp1_->uri;
#line 96 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp3_ = NULL;
#line 96 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp3_ = soup_message_new ("GET", _data_->_tmp2_);
#line 96 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data79_->msg = _data_->_tmp3_;
#line 97 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp4_ = NULL;
#line 97 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp4_ = _data_->_data79_->msg;
#line 97 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp5_ = NULL;
#line 97 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp5_ = soup_message_get_address (_data_->_tmp4_);
#line 97 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp6_ = NULL;
#line 97 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp6_ = _g_object_ref0 (_data_->_tmp5_);
#line 97 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->address = _data_->_tmp6_;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp7_ = NULL;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp7_ = _data_->address;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp8_ = NULL;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp8_ = soup_address_get_name (_data_->_tmp7_);
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp9_ = NULL;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp9_ = _data_->_tmp8_;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp10_ = NULL;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp10_ = _data_->address;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp11_ = 0;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp11_ = soup_address_get_port (_data_->_tmp10_);
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp12_ = 0;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp12_ = _data_->_tmp11_;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp13_ = NULL;
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp13_ = (GNetworkAddress*) g_network_address_new (_data_->_tmp9_, (guint16) _data_->_tmp12_);
#line 98 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->connectable = _data_->_tmp13_;
#line 99 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp14_ = NULL;
#line 99 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp14_ = g_network_monitor_get_default ();
#line 99 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp15_ = NULL;
#line 99 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp15_ = _g_object_ref0 (_data_->_tmp14_);
#line 99 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->network_monitor = _data_->_tmp15_;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp17_ = NULL;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp17_ = _data_->network_monitor;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp18_ = NULL;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp18_ = _data_->connectable;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_state_ = 1;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_network_monitor_can_reach_async (_data_->_tmp17_, (GSocketConnectable*) _data_->_tmp18_, NULL, boxes_downloader_download_from_http_ready, _data_);
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 1823 "downloader.c"
	_state_1:
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp19_ = FALSE;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp19_ = g_network_monitor_can_reach_finish (_data_->_tmp17_, _data_->_res_, &_data_->_inner_error_);
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp16_ = _data_->_tmp19_;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_inner_error_ != NULL) {
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_error_free (_data_->_inner_error_);
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->network_monitor);
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->connectable);
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->address);
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		block79_data_unref (_data_->_data79_);
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_data79_ = NULL;
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_state_ == 0) {
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 1851 "downloader.c"
		} else {
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete (_data_->_async_result);
#line 1855 "downloader.c"
		}
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_unref (_data_->_async_result);
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 1861 "downloader.c"
	}
#line 100 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (!_data_->_tmp16_) {
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp20_ = NULL;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp20_ = _data_->address;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp21_ = NULL;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp21_ = soup_address_get_name (_data_->_tmp20_);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp22_ = NULL;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp22_ = _data_->_tmp21_;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp23_ = NULL;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp23_ = _data_->address;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp24_ = 0;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp24_ = soup_address_get_port (_data_->_tmp23_);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp25_ = 0;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp25_ = _data_->_tmp24_;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp26_ = NULL;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp26_ = g_error_new (BOXES_ERROR, BOXES_ERROR_INVALID, "Failed to reach host '%s' on port '%d'", _data_->_tmp22_, _data_->_tmp25_);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_inner_error_ = _data_->_tmp26_;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_error_free (_data_->_inner_error_);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->network_monitor);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->connectable);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->address);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		block79_data_unref (_data_->_data79_);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_data79_ = NULL;
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_state_ == 0) {
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 1913 "downloader.c"
		} else {
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete (_data_->_async_result);
#line 1917 "downloader.c"
		}
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_unref (_data_->_async_result);
#line 101 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 1923 "downloader.c"
	}
#line 103 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data79_->total_num_bytes = (gint64) 0;
#line 104 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp27_ = NULL;
#line 104 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp27_ = _data_->_data79_->msg;
#line 104 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_signal_connect_data (_data_->_tmp27_, "got-headers", (GCallback) ___lambda54__soup_message_got_headers, block79_data_ref (_data_->_data79_), (GClosureNotify) block79_data_unref, 0);
#line 108 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data79_->current_num_bytes = (gint64) 0;
#line 109 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp28_ = NULL;
#line 109 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp28_ = _data_->_data79_->msg;
#line 109 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_signal_connect_data (_data_->_tmp28_, "got-chunk", (GCallback) ___lambda55__soup_message_got_chunk, block79_data_ref (_data_->_data79_), (GClosureNotify) block79_data_unref, 0);
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp29_ = NULL;
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp29_ = _data_->self->priv->session;
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp30_ = NULL;
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp30_ = _data_->_data79_->msg;
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp31_ = NULL;
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp31_ = _g_object_ref0 (_data_->_tmp30_);
#line 117 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	soup_session_queue_message ((SoupSession*) _data_->_tmp29_, _data_->_tmp31_, ___lambda56__soup_session_callback, block79_data_ref (_data_->_data79_));
#line 120 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_state_ = 2;
#line 120 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 1959 "downloader.c"
	_state_2:
	;
#line 121 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp32_ = NULL;
#line 121 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp32_ = _data_->_data79_->msg;
#line 121 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp33_ = 0U;
#line 121 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_object_get (_data_->_tmp32_, "status-code", &_data_->_tmp33_, NULL);
#line 121 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp34_ = 0U;
#line 121 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp34_ = _data_->_tmp33_;
#line 121 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_tmp34_ != ((guint) SOUP_STATUS_OK)) {
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp35_ = NULL;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp35_ = _data_->_data79_->msg;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp36_ = NULL;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_get (_data_->_tmp35_, "reason-phrase", &_data_->_tmp36_, NULL);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp37_ = NULL;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp37_ = _data_->_tmp36_;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp38_ = NULL;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp38_ = _data_->_tmp37_;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp39_ = NULL;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp39_ = g_error_new_literal (BOXES_ERROR, BOXES_ERROR_INVALID, _data_->_tmp38_);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp40_ = NULL;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp40_ = _data_->_tmp39_;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_free0 (_data_->_tmp38_);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_inner_error_ = _data_->_tmp40_;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_error_free (_data_->_inner_error_);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->network_monitor);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->connectable);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->address);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		block79_data_unref (_data_->_data79_);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_data79_ = NULL;
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_state_ == 0) {
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 2022 "downloader.c"
		} else {
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete (_data_->_async_result);
#line 2026 "downloader.c"
		}
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_unref (_data_->_async_result);
#line 122 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 2032 "downloader.c"
	}
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp41_ = NULL;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp41_ = _data_->_data79_->download;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp42_ = NULL;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp42_ = _data_->_tmp41_->cached_file;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp43_ = NULL;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp43_ = _data_->_data79_->msg;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp44_ = NULL;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp44_ = _data_->_tmp43_->response_body;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp45_ = NULL;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp45__length1 = 0;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp45_ = _data_->_tmp44_->data;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp45__length1 = (gint) _data_->_tmp44_->length;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_state_ = 3;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_file_replace_contents_async (_data_->_tmp42_, _data_->_tmp45_, (gsize) _data_->_tmp45__length1, NULL, FALSE, 0, NULL, boxes_downloader_download_from_http_ready, _data_);
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 2064 "downloader.c"
	_state_3:
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_file_replace_contents_finish (_data_->_tmp42_, _data_->_res_, NULL, &_data_->_inner_error_);
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_inner_error_ != NULL) {
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_error_free (_data_->_inner_error_);
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->network_monitor);
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->connectable);
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->address);
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		block79_data_unref (_data_->_data79_);
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_data79_ = NULL;
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_state_ == 0) {
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 2088 "downloader.c"
		} else {
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete (_data_->_async_result);
#line 2092 "downloader.c"
		}
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_unref (_data_->_async_result);
#line 123 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 2098 "downloader.c"
	}
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->network_monitor);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->connectable);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->address);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	block79_data_unref (_data_->_data79_);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data79_ = NULL;
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_state_ == 0) {
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 2114 "downloader.c"
	} else {
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete (_data_->_async_result);
#line 2118 "downloader.c"
	}
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_object_unref (_data_->_async_result);
#line 95 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 2124 "downloader.c"
}


static void boxes_downloader_fetch_os_logo_data_free (gpointer _data) {
	BoxesDownloaderFetchOsLogoData* _data_;
	_data_ = _data;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->image);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->os);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_slice_free (BoxesDownloaderFetchOsLogoData, _data_);
#line 2137 "downloader.c"
}


void boxes_downloader_fetch_os_logo (GtkImage* image, OsinfoOs* os, gint size, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	BoxesDownloaderFetchOsLogoData* _data_;
	GtkImage* _tmp0_ = NULL;
	GtkImage* _tmp1_ = NULL;
	OsinfoOs* _tmp2_ = NULL;
	OsinfoOs* _tmp3_ = NULL;
	gint _tmp4_ = 0;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = g_slice_new0 (BoxesDownloaderFetchOsLogoData);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_async_result = g_simple_async_result_new (NULL, _callback_, _user_data_, boxes_downloader_fetch_os_logo);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, boxes_downloader_fetch_os_logo_data_free);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = image;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->image);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->image = _tmp1_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = os;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp3_ = _g_object_ref0 (_tmp2_);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->os);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->os = _tmp3_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp4_ = size;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->size = _tmp4_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_fetch_os_logo_co (_data_);
#line 2176 "downloader.c"
}


void boxes_downloader_fetch_os_logo_finish (GAsyncResult* _res_) {
	BoxesDownloaderFetchOsLogoData* _data_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
#line 2184 "downloader.c"
}


static void boxes_downloader_fetch_os_logo_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	BoxesDownloaderFetchOsLogoData* _data_;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = _user_data_;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_source_object_ = source_object;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_res_ = _res_;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_fetch_os_logo_co (_data_);
#line 2198 "downloader.c"
}


static gboolean boxes_downloader_fetch_os_logo_co (BoxesDownloaderFetchOsLogoData* _data_) {
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	switch (_data_->_state_) {
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 0:
#line 2207 "downloader.c"
		goto _state_0;
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 1:
#line 2211 "downloader.c"
		goto _state_1;
		default:
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_assert_not_reached ();
#line 2216 "downloader.c"
	}
	_state_0:
#line 127 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp0_ = NULL;
#line 127 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp0_ = _data_->os;
#line 127 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp1_ = NULL;
#line 127 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp1_ = boxes_downloader_fetch_os_logo_url (_data_->_tmp0_);
#line 127 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->logo_url = _data_->_tmp1_;
#line 128 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp2_ = NULL;
#line 128 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp2_ = _data_->logo_url;
#line 128 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_tmp2_ == NULL) {
#line 129 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_free0 (_data_->logo_url);
#line 129 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_state_ == 0) {
#line 129 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 2241 "downloader.c"
		} else {
#line 129 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete (_data_->_async_result);
#line 2245 "downloader.c"
		}
#line 129 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_unref (_data_->_async_result);
#line 129 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 2251 "downloader.c"
	}
#line 131 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp3_ = NULL;
#line 131 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp3_ = _data_->os;
#line 131 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp4_ = NULL;
#line 131 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp4_ = osinfo_product_get_name ((OsinfoProduct*) _data_->_tmp3_);
#line 131 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp5_ = NULL;
#line 131 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp5_ = _data_->_tmp4_;
#line 131 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp6_ = NULL;
#line 131 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp6_ = _data_->logo_url;
#line 131 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_debug ("downloader.vala:131: %s has logo '%s'.", _data_->_tmp5_, _data_->_tmp6_);
#line 133 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp7_ = NULL;
#line 133 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp7_ = _data_->logo_url;
#line 133 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp8_ = NULL;
#line 133 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp8_ = g_file_new_for_uri (_data_->_tmp7_);
#line 133 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->remote_file = _data_->_tmp8_;
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp9_ = NULL;
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp9_ = _data_->remote_file;
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp10_ = NULL;
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp10_ = g_file_get_basename (_data_->_tmp9_);
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp11_ = NULL;
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp11_ = _data_->_tmp10_;
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp12_ = NULL;
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp12_ = boxes_get_logo_cache (_data_->_tmp11_);
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp13_ = NULL;
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp13_ = _data_->_tmp12_;
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->_tmp11_);
#line 134 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->cached_path = _data_->_tmp13_;
#line 2305 "downloader.c"
	{
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp14_ = NULL;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp14_ = boxes_downloader_get_instance ();
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp15_ = NULL;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp15_ = _data_->_tmp14_;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp16_ = NULL;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp16_ = _data_->remote_file;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp17_ = NULL;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp17_ = _data_->cached_path;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp18_ = NULL;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp18_ = boxes_activity_progress_new ();
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp19_ = NULL;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp19_ = _data_->_tmp18_;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_state_ = 1;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		boxes_downloader_download (_data_->_tmp15_, _data_->_tmp16_, _data_->_tmp17_, _data_->_tmp19_, boxes_downloader_fetch_os_logo_ready, _data_);
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 2337 "downloader.c"
		_state_1:
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp20_ = NULL;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp20_ = boxes_downloader_download_finish (_data_->_tmp15_, _data_->_res_, &_data_->_inner_error_);
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp21_ = NULL;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp21_ = _data_->_tmp20_;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->_tmp19_);
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->_tmp15_);
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->cached_file = _data_->_tmp21_;
#line 136 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_inner_error_ != NULL) {
#line 2355 "downloader.c"
			goto __catch114_g_error;
		}
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp22_ = NULL;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp22_ = _data_->cached_file;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp23_ = NULL;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp23_ = g_file_get_path (_data_->_tmp22_);
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp24_ = NULL;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp24_ = _data_->_tmp23_;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp25_ = 0;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp25_ = _data_->size;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp26_ = 0;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp26_ = _data_->size;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp27_ = NULL;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp27_ = gdk_pixbuf_new_from_file_at_size (_data_->_tmp24_, _data_->_tmp25_, _data_->_tmp26_, &_data_->_inner_error_);
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp28_ = NULL;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp28_ = _data_->_tmp27_;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_free0 (_data_->_tmp24_);
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->pixbuf = _data_->_tmp28_;
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_inner_error_ != NULL) {
#line 137 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_g_object_unref0 (_data_->cached_file);
#line 2394 "downloader.c"
			goto __catch114_g_error;
		}
#line 138 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp29_ = NULL;
#line 138 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp29_ = _data_->image;
#line 138 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp30_ = NULL;
#line 138 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp30_ = _data_->pixbuf;
#line 138 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		gtk_image_set_from_pixbuf (_data_->_tmp29_, _data_->_tmp30_);
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->pixbuf);
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->cached_file);
#line 2411 "downloader.c"
	}
	goto __finally114;
	__catch114_g_error:
	{
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_error_ = _data_->_inner_error_;
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_inner_error_ = NULL;
#line 140 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp31_ = NULL;
#line 140 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp31_ = _data_->logo_url;
#line 140 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp32_ = NULL;
#line 140 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp32_ = _data_->_error_;
#line 140 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp33_ = NULL;
#line 140 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp33_ = _data_->_tmp32_->message;
#line 140 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_warning ("downloader.vala:140: Error loading logo file '%s': %s", _data_->_tmp31_, _data_->_tmp33_);
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_error_free0 (_data_->_error_);
#line 2436 "downloader.c"
	}
	__finally114:
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_inner_error_ != NULL) {
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_free0 (_data_->cached_path);
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->remote_file);
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_free0 (_data_->logo_url);
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error_->message, g_quark_to_string (_data_->_inner_error_->domain), _data_->_inner_error_->code);
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_clear_error (&_data_->_inner_error_);
#line 135 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 2453 "downloader.c"
	}
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->cached_path);
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->remote_file);
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->logo_url);
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_state_ == 0) {
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 2465 "downloader.c"
	} else {
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete (_data_->_async_result);
#line 2469 "downloader.c"
	}
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_object_unref (_data_->_async_result);
#line 126 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 2475 "downloader.c"
}


static void boxes_downloader_await_download_data_free (gpointer _data) {
	BoxesDownloaderAwaitDownloadData* _data_;
	_data_ = _data;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->cached_path);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->progress);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->result);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->self);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_slice_free (BoxesDownloaderAwaitDownloadData, _data_);
#line 2492 "downloader.c"
}


static void boxes_downloader_await_download (BoxesDownloader* self, BoxesDownload* download, const gchar* cached_path, BoxesActivityProgress* progress, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	BoxesDownloaderAwaitDownloadData* _data_;
	BoxesDownloader* _tmp0_ = NULL;
	BoxesDownload* _tmp1_ = NULL;
	BoxesDownload* _tmp2_ = NULL;
	const gchar* _tmp3_ = NULL;
	gchar* _tmp4_ = NULL;
	BoxesActivityProgress* _tmp5_ = NULL;
	BoxesActivityProgress* _tmp6_ = NULL;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = g_slice_new0 (BoxesDownloaderAwaitDownloadData);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, boxes_downloader_await_download);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, boxes_downloader_await_download_data_free);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = _g_object_ref0 (self);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->self = _tmp0_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = download;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = _boxes_download_ref0 (_tmp1_);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_boxes_download_unref0 (_data_->download);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->download = _tmp2_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp3_ = cached_path;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp4_ = g_strdup (_tmp3_);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->cached_path);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->cached_path = _tmp4_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp5_ = progress;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp6_ = _g_object_ref0 (_tmp5_);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->progress);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->progress = _tmp6_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_await_download_co (_data_);
#line 2541 "downloader.c"
}


static GFile* boxes_downloader_await_download_finish (BoxesDownloader* self, GAsyncResult* _res_, GError** error) {
	GFile* result;
	BoxesDownloaderAwaitDownloadData* _data_;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (_res_), error)) {
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return NULL;
#line 2552 "downloader.c"
	}
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	result = _data_->result;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->result = NULL;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return result;
#line 2562 "downloader.c"
}


static Block80Data* block80_data_ref (Block80Data* _data80_) {
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_atomic_int_inc (&_data80_->_ref_count_);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return _data80_;
#line 2571 "downloader.c"
}


static void block80_data_unref (void * _userdata_) {
	Block80Data* _data80_;
	_data80_ = (Block80Data*) _userdata_;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (g_atomic_int_dec_and_test (&_data80_->_ref_count_)) {
#line 2580 "downloader.c"
		BoxesDownloader * self;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		self = _data80_->self;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		(_data80_->callback_target_destroy_notify == NULL) ? NULL : (_data80_->callback_target_destroy_notify (_data80_->callback_target), NULL);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data80_->callback = NULL;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data80_->callback_target = NULL;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data80_->callback_target_destroy_notify = NULL;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_error_free0 (_data80_->download_error);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data80_->downloaded_file);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_boxes_download_unref0 (_data80_->download);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (self);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_slice_free (Block80Data, _data80_);
#line 2602 "downloader.c"
	}
}


static gboolean _boxes_downloader_await_download_co_gsource_func (gpointer self) {
	gboolean result;
	result = boxes_downloader_await_download_co (self);
#line 151 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return result;
#line 2612 "downloader.c"
}


static void __lambda52_ (Block80Data* _data80_, BoxesDownloader* downloader, BoxesDownload* downloaded) {
	BoxesDownloader * self;
	BoxesDownload* _tmp0_ = NULL;
	const gchar* _tmp1_ = NULL;
	BoxesDownload* _tmp2_ = NULL;
	const gchar* _tmp3_ = NULL;
	BoxesDownload* _tmp4_ = NULL;
	GFile* _tmp5_ = NULL;
	GFile* _tmp6_ = NULL;
#line 152 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self = _data80_->self;
#line 152 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (downloader != NULL);
#line 152 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (downloaded != NULL);
#line 153 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = downloaded;
#line 153 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = _tmp0_->uri;
#line 153 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = _data80_->download;
#line 153 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp3_ = _tmp2_->uri;
#line 153 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (g_strcmp0 (_tmp1_, _tmp3_) != 0) {
#line 154 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return;
#line 2643 "downloader.c"
	}
#line 156 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp4_ = downloaded;
#line 156 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp5_ = _tmp4_->cached_file;
#line 156 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp6_ = _g_object_ref0 (_tmp5_);
#line 156 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data80_->downloaded_file);
#line 156 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data80_->downloaded_file = _tmp6_;
#line 157 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data80_->callback (_data80_->callback_target);
#line 2657 "downloader.c"
}


static void ___lambda52__boxes_downloader_downloaded (BoxesDownloader* _sender, BoxesDownload* download, gpointer self) {
#line 152 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	__lambda52_ (self, _sender, download);
#line 2664 "downloader.c"
}


static void __lambda53_ (Block80Data* _data80_, BoxesDownloader* downloader, BoxesDownload* failed_download, GError* _error_) {
	BoxesDownloader * self;
	BoxesDownload* _tmp0_ = NULL;
	const gchar* _tmp1_ = NULL;
	BoxesDownload* _tmp2_ = NULL;
	const gchar* _tmp3_ = NULL;
	GError* _tmp4_ = NULL;
	GError* _tmp5_ = NULL;
#line 159 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self = _data80_->self;
#line 159 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (downloader != NULL);
#line 159 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (failed_download != NULL);
#line 160 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp0_ = failed_download;
#line 160 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp1_ = _tmp0_->uri;
#line 160 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp2_ = _data80_->download;
#line 160 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp3_ = _tmp2_->uri;
#line 160 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (g_strcmp0 (_tmp1_, _tmp3_) != 0) {
#line 161 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return;
#line 2694 "downloader.c"
	}
#line 163 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp4_ = _error_;
#line 163 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_tmp5_ = _g_error_copy0 (_tmp4_);
#line 163 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_error_free0 (_data80_->download_error);
#line 163 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data80_->download_error = _tmp5_;
#line 164 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data80_->callback (_data80_->callback_target);
#line 2706 "downloader.c"
}


static void ___lambda53__boxes_downloader_download_failed (BoxesDownloader* _sender, BoxesDownload* download, GError* _error_, gpointer self) {
#line 159 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	__lambda53_ (self, _sender, download, _error_);
#line 2713 "downloader.c"
}


static void boxes_downloader_await_download_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	BoxesDownloaderAwaitDownloadData* _data_;
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_ = _user_data_;
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_source_object_ = source_object;
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_res_ = _res_;
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_await_download_co (_data_);
#line 2727 "downloader.c"
}


static gboolean boxes_downloader_await_download_co (BoxesDownloaderAwaitDownloadData* _data_) {
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	switch (_data_->_state_) {
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 0:
#line 2736 "downloader.c"
		goto _state_0;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 1:
#line 2740 "downloader.c"
		goto _state_1;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		case 2:
#line 2744 "downloader.c"
		goto _state_2;
		default:
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_assert_not_reached ();
#line 2749 "downloader.c"
	}
	_state_0:
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_ = g_slice_new0 (Block80Data);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_->_ref_count_ = 1;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_->self = g_object_ref (_data_->self);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp0_ = NULL;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp0_ = _data_->download;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_boxes_download_unref0 (_data_->_data80_->download);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_->download = _data_->_tmp0_;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_->_async_data_ = _data_;
#line 147 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_->downloaded_file = NULL;
#line 148 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_->download_error = NULL;
#line 150 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp1_ = NULL;
#line 150 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp1_ = _data_->_data80_->download;
#line 150 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp2_ = NULL;
#line 150 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp2_ = _data_->_tmp1_->progress;
#line 150 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp3_ = NULL;
#line 150 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp3_ = _data_->progress;
#line 150 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_object_bind_property_with_closures ((GObject*) _data_->_tmp2_, "progress", (GObject*) _data_->_tmp3_, "progress", G_BINDING_SYNC_CREATE, (GClosure*) ((NULL == NULL) ? NULL : g_cclosure_new ((GCallback) NULL, NULL, NULL)), (GClosure*) ((NULL == NULL) ? NULL : g_cclosure_new ((GCallback) NULL, NULL, NULL)));
#line 151 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_->callback = _boxes_downloader_await_download_co_gsource_func;
#line 151 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_->callback_target = _data_;
#line 151 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_->callback_target_destroy_notify = NULL;
#line 152 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp4_ = 0UL;
#line 152 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp4_ = g_signal_connect_data (_data_->self, "downloaded", (GCallback) ___lambda52__boxes_downloader_downloaded, block80_data_ref (_data_->_data80_), (GClosureNotify) block80_data_unref, 0);
#line 152 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->downloaded_id = _data_->_tmp4_;
#line 159 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp5_ = 0UL;
#line 159 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp5_ = g_signal_connect_data (_data_->self, "download-failed", (GCallback) ___lambda53__boxes_downloader_download_failed, block80_data_ref (_data_->_data80_), (GClosureNotify) block80_data_unref, 0);
#line 159 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->downloaded_failed_id = _data_->_tmp5_;
#line 167 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp6_ = NULL;
#line 167 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp6_ = _data_->_data80_->download;
#line 167 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp7_ = NULL;
#line 167 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp7_ = _data_->_tmp6_->uri;
#line 167 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_debug ("downloader.vala:167: '%s' already being downloaded. Waiting for downlo" \
"ad to complete..", _data_->_tmp7_);
#line 168 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_state_ = 1;
#line 168 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 2818 "downloader.c"
	_state_1:
	;
#line 169 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp8_ = NULL;
#line 169 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp8_ = _data_->_data80_->download;
#line 169 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp9_ = NULL;
#line 169 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp9_ = _data_->_tmp8_->uri;
#line 169 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_debug ("downloader.vala:169: Finished waiting for '%s' to download.", _data_->_tmp9_);
#line 170 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_signal_handler_disconnect ((GObject*) _data_->self, _data_->downloaded_id);
#line 171 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_signal_handler_disconnect ((GObject*) _data_->self, _data_->downloaded_failed_id);
#line 173 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_data80_->download_error != NULL) {
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp10_ = NULL;
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp10_ = _g_error_copy0 (_data_->_data80_->download_error);
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_inner_error_ = _data_->_tmp10_;
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_error_free (_data_->_inner_error_);
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		block80_data_unref (_data_->_data80_);
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_data80_ = NULL;
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_state_ == 0) {
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 2855 "downloader.c"
		} else {
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_complete (_data_->_async_result);
#line 2859 "downloader.c"
		}
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_object_unref (_data_->_async_result);
#line 174 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 2865 "downloader.c"
	}
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp11_ = NULL;
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp11_ = g_file_get_path (_data_->_data80_->downloaded_file);
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp12_ = NULL;
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp12_ = _data_->_tmp11_;
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp13_ = NULL;
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp13_ = _data_->cached_path;
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp14_ = FALSE;
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_tmp14_ = g_strcmp0 (_data_->_tmp12_, _data_->_tmp13_) != 0;
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_free0 (_data_->_tmp12_);
#line 177 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_tmp14_) {
#line 178 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp15_ = NULL;
#line 178 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp15_ = _data_->cached_path;
#line 178 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp16_ = NULL;
#line 178 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp16_ = g_file_new_for_path (_data_->_tmp15_);
#line 178 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->cached_file);
#line 178 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->cached_file = _data_->_tmp16_;
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp17_ = NULL;
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp17_ = _data_->cached_file;
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_state_ = 2;
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_file_copy_async (_data_->_data80_->downloaded_file, _data_->_tmp17_, G_FILE_COPY_OVERWRITE, G_PRIORITY_DEFAULT, NULL, NULL, NULL, boxes_downloader_await_download_ready, _data_);
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		return FALSE;
#line 2909 "downloader.c"
		_state_2:
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_file_copy_finish (_data_->_data80_->downloaded_file, _data_->_res_, &_data_->_inner_error_);
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		if (_data_->_inner_error_ != NULL) {
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_);
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_error_free (_data_->_inner_error_);
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_g_object_unref0 (_data_->cached_file);
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			block80_data_unref (_data_->_data80_);
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			_data_->_data80_ = NULL;
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			if (_data_->_state_ == 0) {
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
				g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 2929 "downloader.c"
			} else {
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
				g_simple_async_result_complete (_data_->_async_result);
#line 2933 "downloader.c"
			}
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			g_object_unref (_data_->_async_result);
#line 179 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
			return FALSE;
#line 2939 "downloader.c"
		}
	} else {
#line 181 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp18_ = NULL;
#line 181 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->_tmp18_ = _g_object_ref0 (_data_->_data80_->downloaded_file);
#line 181 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_g_object_unref0 (_data_->cached_file);
#line 181 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		_data_->cached_file = _data_->_tmp18_;
#line 2950 "downloader.c"
	}
#line 183 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->result = _data_->cached_file;
#line 183 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	block80_data_unref (_data_->_data80_);
#line 183 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_ = NULL;
#line 183 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_state_ == 0) {
#line 183 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 2962 "downloader.c"
	} else {
#line 183 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete (_data_->_async_result);
#line 2966 "downloader.c"
	}
#line 183 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_object_unref (_data_->_async_result);
#line 183 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (_data_->cached_file);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	block80_data_unref (_data_->_data80_);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_data_->_data80_ = NULL;
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (_data_->_state_ == 0) {
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete_in_idle (_data_->_async_result);
#line 2982 "downloader.c"
	} else {
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		g_simple_async_result_complete (_data_->_async_result);
#line 2986 "downloader.c"
	}
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_object_unref (_data_->_async_result);
#line 144 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	return FALSE;
#line 2992 "downloader.c"
}


static void g_cclosure_user_marshal_VOID__BOXES_DOWNLOAD (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) {
	typedef void (*GMarshalFunc_VOID__BOXES_DOWNLOAD) (gpointer data1, gpointer arg_1, gpointer data2);
	register GMarshalFunc_VOID__BOXES_DOWNLOAD callback;
	register GCClosure * cc;
	register gpointer data1;
	register gpointer data2;
	cc = (GCClosure *) closure;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (n_param_values == 2);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (G_CCLOSURE_SWAP_DATA (closure)) {
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		data1 = closure->data;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		data2 = param_values->data[0].v_pointer;
#line 3011 "downloader.c"
	} else {
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		data1 = param_values->data[0].v_pointer;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		data2 = closure->data;
#line 3017 "downloader.c"
	}
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	callback = (GMarshalFunc_VOID__BOXES_DOWNLOAD) (marshal_data ? marshal_data : cc->callback);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	callback (data1, boxes_value_get_download (param_values + 1), data2);
#line 3023 "downloader.c"
}


static void g_cclosure_user_marshal_VOID__BOXES_DOWNLOAD_POINTER (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) {
	typedef void (*GMarshalFunc_VOID__BOXES_DOWNLOAD_POINTER) (gpointer data1, gpointer arg_1, gpointer arg_2, gpointer data2);
	register GMarshalFunc_VOID__BOXES_DOWNLOAD_POINTER callback;
	register GCClosure * cc;
	register gpointer data1;
	register gpointer data2;
	cc = (GCClosure *) closure;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_return_if_fail (n_param_values == 3);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	if (G_CCLOSURE_SWAP_DATA (closure)) {
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		data1 = closure->data;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		data2 = param_values->data[0].v_pointer;
#line 3042 "downloader.c"
	} else {
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		data1 = param_values->data[0].v_pointer;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
		data2 = closure->data;
#line 3048 "downloader.c"
	}
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	callback = (GMarshalFunc_VOID__BOXES_DOWNLOAD_POINTER) (marshal_data ? marshal_data : cc->callback);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	callback (data1, boxes_value_get_download (param_values + 1), g_value_get_pointer (param_values + 2), data2);
#line 3054 "downloader.c"
}


static void boxes_downloader_class_init (BoxesDownloaderClass * klass) {
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	boxes_downloader_parent_class = g_type_class_peek_parent (klass);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_type_class_add_private (klass, sizeof (BoxesDownloaderPrivate));
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	G_OBJECT_CLASS (klass)->finalize = boxes_downloader_finalize;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_signal_new ("downloaded", BOXES_TYPE_DOWNLOADER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__BOXES_DOWNLOAD, G_TYPE_NONE, 1, BOXES_TYPE_DOWNLOAD);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	g_signal_new ("download_failed", BOXES_TYPE_DOWNLOADER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__BOXES_DOWNLOAD_POINTER, G_TYPE_NONE, 2, BOXES_TYPE_DOWNLOAD, G_TYPE_POINTER);
#line 3069 "downloader.c"
}


static void boxes_downloader_instance_init (BoxesDownloader * self) {
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self->priv = BOXES_DOWNLOADER_GET_PRIVATE (self);
#line 3076 "downloader.c"
}


static void boxes_downloader_finalize (GObject* obj) {
	BoxesDownloader * self;
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, BOXES_TYPE_DOWNLOADER, BoxesDownloader);
#line 17 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_object_unref0 (self->priv->session);
#line 19 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	_g_hash_table_unref0 (self->priv->downloads);
#line 15 "/extra-data/checkout/gnome/gnome-boxes/src/downloader.vala"
	G_OBJECT_CLASS (boxes_downloader_parent_class)->finalize (obj);
#line 3090 "downloader.c"
}


GType boxes_downloader_get_type (void) {
	static volatile gsize boxes_downloader_type_id__volatile = 0;
	if (g_once_init_enter (&boxes_downloader_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (BoxesDownloaderClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) boxes_downloader_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (BoxesDownloader), 0, (GInstanceInitFunc) boxes_downloader_instance_init, NULL };
		GType boxes_downloader_type_id;
		boxes_downloader_type_id = g_type_register_static (G_TYPE_OBJECT, "BoxesDownloader", &g_define_type_info, 0);
		g_once_init_leave (&boxes_downloader_type_id__volatile, boxes_downloader_type_id);
	}
	return boxes_downloader_type_id__volatile;
}



