/* rygel-media-art-store.c generated by valac 0.17.2.19-5f50d, the Vala compiler
 * generated from rygel-media-art-store.vala, do not modify */

/*
 * Copyright (C) 2010 Jens Georg <mail@jensge.org>.
 *
 * Author: Jens Georg <mail@jensge.org>
 *
 * This file is part of Rygel.
 *
 * Rygel is free software; you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * Rygel is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 */

#include <glib.h>
#include <glib-object.h>
#include <stdlib.h>
#include <string.h>
#include <gio/gio.h>
#include <glib/gstdio.h>


#define RYGEL_TYPE_MEDIA_ART_STORE (rygel_media_art_store_get_type ())
#define RYGEL_MEDIA_ART_STORE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_TYPE_MEDIA_ART_STORE, RygelMediaArtStore))
#define RYGEL_MEDIA_ART_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_TYPE_MEDIA_ART_STORE, RygelMediaArtStoreClass))
#define RYGEL_IS_MEDIA_ART_STORE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_TYPE_MEDIA_ART_STORE))
#define RYGEL_IS_MEDIA_ART_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_TYPE_MEDIA_ART_STORE))
#define RYGEL_MEDIA_ART_STORE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_TYPE_MEDIA_ART_STORE, RygelMediaArtStoreClass))

typedef struct _RygelMediaArtStore RygelMediaArtStore;
typedef struct _RygelMediaArtStoreClass RygelMediaArtStoreClass;
typedef struct _RygelMediaArtStorePrivate RygelMediaArtStorePrivate;
#define _g_regex_unref0(var) ((var == NULL) ? NULL : (var = (g_regex_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))

#define RYGEL_TYPE_MEDIA_ITEM (rygel_media_item_get_type ())
#define RYGEL_MEDIA_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_TYPE_MEDIA_ITEM, RygelMediaItem))
#define RYGEL_MEDIA_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_TYPE_MEDIA_ITEM, RygelMediaItemClass))
#define RYGEL_IS_MEDIA_ITEM(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_TYPE_MEDIA_ITEM))
#define RYGEL_IS_MEDIA_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_TYPE_MEDIA_ITEM))
#define RYGEL_MEDIA_ITEM_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_TYPE_MEDIA_ITEM, RygelMediaItemClass))

typedef struct _RygelMediaItem RygelMediaItem;
typedef struct _RygelMediaItemClass RygelMediaItemClass;

#define RYGEL_TYPE_AUDIO_ITEM (rygel_audio_item_get_type ())
#define RYGEL_AUDIO_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_TYPE_AUDIO_ITEM, RygelAudioItem))
#define RYGEL_AUDIO_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_TYPE_AUDIO_ITEM, RygelAudioItemClass))
#define RYGEL_IS_AUDIO_ITEM(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_TYPE_AUDIO_ITEM))
#define RYGEL_IS_AUDIO_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_TYPE_AUDIO_ITEM))
#define RYGEL_AUDIO_ITEM_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_TYPE_AUDIO_ITEM, RygelAudioItemClass))

typedef struct _RygelAudioItem RygelAudioItem;
typedef struct _RygelAudioItemClass RygelAudioItemClass;

#define RYGEL_TYPE_MUSIC_ITEM (rygel_music_item_get_type ())
#define RYGEL_MUSIC_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_TYPE_MUSIC_ITEM, RygelMusicItem))
#define RYGEL_MUSIC_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_TYPE_MUSIC_ITEM, RygelMusicItemClass))
#define RYGEL_IS_MUSIC_ITEM(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_TYPE_MUSIC_ITEM))
#define RYGEL_IS_MUSIC_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_TYPE_MUSIC_ITEM))
#define RYGEL_MUSIC_ITEM_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_TYPE_MUSIC_ITEM, RygelMusicItemClass))

typedef struct _RygelMusicItem RygelMusicItem;
typedef struct _RygelMusicItemClass RygelMusicItemClass;

#define RYGEL_TYPE_ICON_INFO (rygel_icon_info_get_type ())
#define RYGEL_ICON_INFO(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_TYPE_ICON_INFO, RygelIconInfo))
#define RYGEL_ICON_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_TYPE_ICON_INFO, RygelIconInfoClass))
#define RYGEL_IS_ICON_INFO(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_TYPE_ICON_INFO))
#define RYGEL_IS_ICON_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_TYPE_ICON_INFO))
#define RYGEL_ICON_INFO_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_TYPE_ICON_INFO, RygelIconInfoClass))

typedef struct _RygelIconInfo RygelIconInfo;
typedef struct _RygelIconInfoClass RygelIconInfoClass;

#define RYGEL_TYPE_THUMBNAIL (rygel_thumbnail_get_type ())
#define RYGEL_THUMBNAIL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), RYGEL_TYPE_THUMBNAIL, RygelThumbnail))
#define RYGEL_THUMBNAIL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), RYGEL_TYPE_THUMBNAIL, RygelThumbnailClass))
#define RYGEL_IS_THUMBNAIL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), RYGEL_TYPE_THUMBNAIL))
#define RYGEL_IS_THUMBNAIL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), RYGEL_TYPE_THUMBNAIL))
#define RYGEL_THUMBNAIL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), RYGEL_TYPE_THUMBNAIL, RygelThumbnailClass))

typedef struct _RygelThumbnail RygelThumbnail;
typedef struct _RygelThumbnailClass RygelThumbnailClass;
typedef struct _RygelIconInfoPrivate RygelIconInfoPrivate;
#define _rygel_icon_info_unref0(var) ((var == NULL) ? NULL : (var = (rygel_icon_info_unref (var), NULL)))
typedef struct _RygelMediaItemPrivate RygelMediaItemPrivate;
typedef struct _RygelAudioItemPrivate RygelAudioItemPrivate;
typedef struct _RygelMusicItemPrivate RygelMusicItemPrivate;

typedef enum  {
	MEDIA_ART_STORE_ERROR_NO_DIR,
	MEDIA_ART_STORE_ERROR_NO_MEDIA_ART
} MediaArtStoreError;
#define MEDIA_ART_STORE_ERROR media_art_store_error_quark ()
struct _RygelMediaArtStore {
	GObject parent_instance;
	RygelMediaArtStorePrivate * priv;
};

struct _RygelMediaArtStoreClass {
	GObjectClass parent_class;
};

struct _RygelMediaArtStorePrivate {
	GRegex* char_remove_regex;
	GRegex* char_convert_regex;
	GRegex* space_compress_regex;
	GRegex** block_regexes;
	gint block_regexes_length1;
	gint _block_regexes_size_;
	gchar* directory;
};

struct _RygelIconInfo {
	GTypeInstance parent_instance;
	volatile int ref_count;
	RygelIconInfoPrivate * priv;
	gchar* mime_type;
	gchar* uri;
	gchar* file_extension;
	gint64 size;
	gint width;
	gint height;
	gint depth;
};

struct _RygelIconInfoClass {
	GTypeClass parent_class;
	void (*finalize) (RygelIconInfo *self);
};

struct _RygelMediaItem {
	GObject parent_instance;
	RygelMediaItemPrivate * priv;
	gchar* title;
};

struct _RygelMediaItemClass {
	GObjectClass parent_class;
};

struct _RygelAudioItem {
	RygelMediaItem parent_instance;
	RygelAudioItemPrivate * priv;
};

struct _RygelAudioItemClass {
	RygelMediaItemClass parent_class;
};

struct _RygelMusicItem {
	RygelAudioItem parent_instance;
	RygelMusicItemPrivate * priv;
	gchar* artist;
	gchar* album;
};

struct _RygelMusicItemClass {
	RygelAudioItemClass parent_class;
};


static gpointer rygel_media_art_store_parent_class = NULL;
static RygelMediaArtStore* rygel_media_art_store_media_art_store;
static RygelMediaArtStore* rygel_media_art_store_media_art_store = NULL;
static gboolean rygel_media_art_store_first_time;
static gboolean rygel_media_art_store_first_time = TRUE;

GQuark media_art_store_error_quark (void);
GType rygel_media_art_store_get_type (void) G_GNUC_CONST;
#define RYGEL_MEDIA_ART_STORE_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), RYGEL_TYPE_MEDIA_ART_STORE, RygelMediaArtStorePrivate))
enum  {
	RYGEL_MEDIA_ART_STORE_DUMMY_PROPERTY
};
#define RYGEL_MEDIA_ART_STORE_PLACEHOLDER_HASH "7215ee9c7d9dc229d2921a40e899ec5f"
#define RYGEL_MEDIA_ART_STORE_invalid_chars "()[]<>{}_!@#$^&*+=|\\/\"'?~"
#define RYGEL_MEDIA_ART_STORE_convert_chars "\t"
#define RYGEL_MEDIA_ART_STORE_block_pattern "%s[^%s]*%s"
RygelMediaArtStore* rygel_media_art_store_get_default (void);
static RygelMediaArtStore* rygel_media_art_store_new (GError** error);
static RygelMediaArtStore* rygel_media_art_store_construct (GType object_type, GError** error);
GType rygel_media_item_get_type (void) G_GNUC_CONST;
GType rygel_audio_item_get_type (void) G_GNUC_CONST;
GType rygel_music_item_get_type (void) G_GNUC_CONST;
gpointer rygel_icon_info_ref (gpointer instance);
void rygel_icon_info_unref (gpointer instance);
GParamSpec* rygel_param_spec_icon_info (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void rygel_value_set_icon_info (GValue* value, gpointer v_object);
void rygel_value_take_icon_info (GValue* value, gpointer v_object);
gpointer rygel_value_get_icon_info (const GValue* value);
GType rygel_icon_info_get_type (void) G_GNUC_CONST;
GType rygel_thumbnail_get_type (void) G_GNUC_CONST;
RygelThumbnail* rygel_media_art_store_find_media_art (RygelMediaArtStore* self, RygelMusicItem* item, gboolean simple, GError** error);
GFile* rygel_media_art_store_get_media_art_file (RygelMediaArtStore* self, const gchar* type, RygelMusicItem* item, gboolean simple);
RygelThumbnail* rygel_thumbnail_new (const gchar* mime_type, const gchar* dlna_profile, const gchar* file_extension);
RygelThumbnail* rygel_thumbnail_construct (GType object_type, const gchar* mime_type, const gchar* dlna_profile, const gchar* file_extension);
RygelThumbnail* rygel_media_art_store_find_media_art_any (RygelMediaArtStore* self, RygelMusicItem* item, GError** error);
static gchar* rygel_media_art_store_get_simple_hash (RygelMediaArtStore* self, const gchar* type, RygelMusicItem* item);
static gchar* rygel_media_art_store_get_hash (RygelMediaArtStore* self, const gchar* type, RygelMusicItem* item);
static void _vala_array_add1 (GRegex*** array, int* length, int* size, GRegex* value);
static gchar* rygel_media_art_store_normalize_and_hash (RygelMediaArtStore* self, const gchar* input, gboolean utf8_only);
static gchar* rygel_media_art_store_strip_invalid_entities (RygelMediaArtStore* self, const gchar* original);
static void rygel_media_art_store_finalize (GObject* obj);
static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func);

static const gchar* RYGEL_MEDIA_ART_STORE_blocks[4] = {"()", "{}", "[]", "<>"};

GQuark media_art_store_error_quark (void) {
	return g_quark_from_static_string ("media_art_store_error-quark");
}


static gpointer _g_object_ref0 (gpointer self) {
#line 54 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return self ? g_object_ref (self) : NULL;
#line 232 "rygel-media-art-store.c"
}


RygelMediaArtStore* rygel_media_art_store_get_default (void) {
	RygelMediaArtStore* result = NULL;
	gboolean _tmp0_;
	RygelMediaArtStore* _tmp5_;
	RygelMediaArtStore* _tmp6_;
	GError * _inner_error_ = NULL;
#line 44 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp0_ = rygel_media_art_store_first_time;
#line 44 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_tmp0_) {
#line 246 "rygel-media-art-store.c"
		{
			RygelMediaArtStore* _tmp1_;
			RygelMediaArtStore* _tmp2_;
#line 46 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp1_ = rygel_media_art_store_new (&_inner_error_);
#line 46 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp2_ = _tmp1_;
#line 46 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			if (_inner_error_ != NULL) {
#line 46 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				if (_inner_error_->domain == MEDIA_ART_STORE_ERROR) {
#line 258 "rygel-media-art-store.c"
					goto __catch0_media_art_store_error;
				}
#line 46 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 46 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				g_clear_error (&_inner_error_);
#line 46 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				return NULL;
#line 267 "rygel-media-art-store.c"
			}
#line 46 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_object_unref0 (rygel_media_art_store_media_art_store);
#line 46 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			rygel_media_art_store_media_art_store = _tmp2_;
#line 273 "rygel-media-art-store.c"
		}
		goto __finally0;
		__catch0_media_art_store_error:
		{
			GError* _error_ = NULL;
			GError* _tmp3_;
			const gchar* _tmp4_;
#line 45 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_error_ = _inner_error_;
#line 45 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_inner_error_ = NULL;
#line 48 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp3_ = _error_;
#line 48 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp4_ = _tmp3_->message;
#line 48 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_warning ("rygel-media-art-store.vala:48: No media art available: %s", _tmp4_);
#line 45 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_error_free0 (_error_);
#line 293 "rygel-media-art-store.c"
		}
		__finally0:
#line 45 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_inner_error_ != NULL) {
#line 45 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 45 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_clear_error (&_inner_error_);
#line 45 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 304 "rygel-media-art-store.c"
		}
	}
#line 52 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	rygel_media_art_store_first_time = FALSE;
#line 54 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp5_ = rygel_media_art_store_media_art_store;
#line 54 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp6_ = _g_object_ref0 (_tmp5_);
#line 54 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	result = _tmp6_;
#line 54 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return result;
#line 317 "rygel-media-art-store.c"
}


RygelThumbnail* rygel_media_art_store_find_media_art (RygelMediaArtStore* self, RygelMusicItem* item, gboolean simple, GError** error) {
	RygelThumbnail* result = NULL;
	gchar* _tmp0_;
	gchar* _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
	gchar* _tmp4_;
	gchar** _tmp5_ = NULL;
	gchar** types;
	gint types_length1;
	gint _types_size_;
	GFile* file;
	gchar** _tmp6_;
	gint _tmp6__length1;
	GFile* _tmp14_;
	GFile* _tmp15_;
	GFileInfo* _tmp16_ = NULL;
	GFileInfo* info;
	GFileInfo* _tmp17_;
	gboolean _tmp18_ = FALSE;
	RygelThumbnail* _tmp19_;
	RygelThumbnail* thumb;
	RygelThumbnail* _tmp20_;
	GFile* _tmp21_;
	gchar* _tmp22_ = NULL;
	RygelThumbnail* _tmp23_;
	GFileInfo* _tmp24_;
	gint64 _tmp25_ = 0LL;
	GError * _inner_error_ = NULL;
#line 57 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 57 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (item != NULL, NULL);
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp0_ = g_strdup ("track");
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp1_ = g_strdup ("album");
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp2_ = g_strdup ("artist");
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp3_ = g_strdup ("podcast");
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp4_ = g_strdup ("radio");
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp5_ = g_new0 (gchar*, 5 + 1);
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp5_[0] = _tmp0_;
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp5_[1] = _tmp1_;
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp5_[2] = _tmp2_;
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp5_[3] = _tmp3_;
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp5_[4] = _tmp4_;
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	types = _tmp5_;
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	types_length1 = 5;
#line 59 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_types_size_ = types_length1;
#line 60 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	file = NULL;
#line 62 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp6_ = types;
#line 62 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp6__length1 = types_length1;
#line 388 "rygel-media-art-store.c"
	{
		gchar** type_collection = NULL;
		gint type_collection_length1 = 0;
		gint _type_collection_size_ = 0;
		gint type_it = 0;
#line 62 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		type_collection = _tmp6_;
#line 62 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		type_collection_length1 = _tmp6__length1;
#line 62 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		for (type_it = 0; type_it < _tmp6__length1; type_it = type_it + 1) {
#line 400 "rygel-media-art-store.c"
			gchar* _tmp7_;
			gchar* type = NULL;
#line 62 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp7_ = g_strdup (type_collection[type_it]);
#line 62 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			type = _tmp7_;
#line 407 "rygel-media-art-store.c"
			{
				const gchar* _tmp8_;
				RygelMusicItem* _tmp9_;
				gboolean _tmp10_;
				GFile* _tmp11_ = NULL;
				GFile* _tmp12_;
				gboolean _tmp13_ = FALSE;
#line 63 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp8_ = type;
#line 63 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp9_ = item;
#line 63 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp10_ = simple;
#line 63 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp11_ = rygel_media_art_store_get_media_art_file (self, _tmp8_, _tmp9_, _tmp10_);
#line 63 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_object_unref0 (file);
#line 63 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				file = _tmp11_;
#line 64 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp12_ = file;
#line 64 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp13_ = g_file_query_exists (_tmp12_, NULL);
#line 64 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				if (_tmp13_) {
#line 65 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_free0 (type);
#line 65 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					break;
#line 437 "rygel-media-art-store.c"
				} else {
#line 67 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_object_unref0 (file);
#line 67 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					file = NULL;
#line 443 "rygel-media-art-store.c"
				}
#line 62 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (type);
#line 447 "rygel-media-art-store.c"
			}
		}
	}
#line 71 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp14_ = file;
#line 71 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_tmp14_ == NULL) {
#line 72 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		result = NULL;
#line 72 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_object_unref0 (file);
#line 72 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		types = (_vala_array_free (types, types_length1, (GDestroyNotify) g_free), NULL);
#line 72 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		return result;
#line 463 "rygel-media-art-store.c"
	}
#line 75 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp15_ = file;
#line 75 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp16_ = g_file_query_info (_tmp15_, G_FILE_ATTRIBUTE_ACCESS_CAN_READ "," G_FILE_ATTRIBUTE_STANDARD_SIZE, G_FILE_QUERY_INFO_NONE, NULL, &_inner_error_);
#line 75 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	info = _tmp16_;
#line 75 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_inner_error_ != NULL) {
#line 75 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		g_propagate_error (error, _inner_error_);
#line 75 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_object_unref0 (file);
#line 75 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		types = (_vala_array_free (types, types_length1, (GDestroyNotify) g_free), NULL);
#line 75 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		return NULL;
#line 481 "rygel-media-art-store.c"
	}
#line 79 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp17_ = info;
#line 79 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp18_ = g_file_info_get_attribute_boolean (_tmp17_, G_FILE_ATTRIBUTE_ACCESS_CAN_READ);
#line 79 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (!_tmp18_) {
#line 80 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		result = NULL;
#line 80 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_object_unref0 (info);
#line 80 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_object_unref0 (file);
#line 80 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		types = (_vala_array_free (types, types_length1, (GDestroyNotify) g_free), NULL);
#line 80 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		return result;
#line 499 "rygel-media-art-store.c"
	}
#line 83 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp19_ = rygel_thumbnail_new ("image/jpeg", "JPEG_TN", "jpg");
#line 83 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	thumb = _tmp19_;
#line 84 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp20_ = thumb;
#line 84 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp21_ = file;
#line 84 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp22_ = g_file_get_uri (_tmp21_);
#line 84 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (((RygelIconInfo*) _tmp20_)->uri);
#line 84 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	((RygelIconInfo*) _tmp20_)->uri = _tmp22_;
#line 85 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp23_ = thumb;
#line 85 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp24_ = info;
#line 85 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp25_ = g_file_info_get_size (_tmp24_);
#line 85 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	((RygelIconInfo*) _tmp23_)->size = (gint64) _tmp25_;
#line 87 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	result = thumb;
#line 87 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_object_unref0 (info);
#line 87 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_object_unref0 (file);
#line 87 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	types = (_vala_array_free (types, types_length1, (GDestroyNotify) g_free), NULL);
#line 87 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return result;
#line 533 "rygel-media-art-store.c"
}


RygelThumbnail* rygel_media_art_store_find_media_art_any (RygelMediaArtStore* self, RygelMusicItem* item, GError** error) {
	RygelThumbnail* result = NULL;
	RygelMusicItem* _tmp0_;
	RygelThumbnail* _tmp1_ = NULL;
	RygelThumbnail* thumb;
	RygelThumbnail* _tmp2_;
	GError * _inner_error_ = NULL;
#line 90 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 90 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (item != NULL, NULL);
#line 91 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp0_ = item;
#line 91 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp1_ = rygel_media_art_store_find_media_art (self, _tmp0_, FALSE, &_inner_error_);
#line 91 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	thumb = _tmp1_;
#line 91 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_inner_error_ != NULL) {
#line 91 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		g_propagate_error (error, _inner_error_);
#line 91 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		return NULL;
#line 560 "rygel-media-art-store.c"
	}
#line 92 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp2_ = thumb;
#line 92 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_tmp2_ == NULL) {
#line 566 "rygel-media-art-store.c"
		RygelMusicItem* _tmp3_;
		RygelThumbnail* _tmp4_ = NULL;
		RygelThumbnail* _tmp5_;
#line 93 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp3_ = item;
#line 93 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp4_ = rygel_media_art_store_find_media_art (self, _tmp3_, TRUE, &_inner_error_);
#line 93 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp5_ = _tmp4_;
#line 93 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_inner_error_ != NULL) {
#line 93 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_propagate_error (error, _inner_error_);
#line 93 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_rygel_icon_info_unref0 (thumb);
#line 93 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 584 "rygel-media-art-store.c"
		}
#line 93 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_rygel_icon_info_unref0 (thumb);
#line 93 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		thumb = _tmp5_;
#line 590 "rygel-media-art-store.c"
	}
#line 96 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	result = thumb;
#line 96 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return result;
#line 596 "rygel-media-art-store.c"
}


GFile* rygel_media_art_store_get_media_art_file (RygelMediaArtStore* self, const gchar* type, RygelMusicItem* item, gboolean simple) {
	GFile* result = NULL;
	gchar* hash = NULL;
	gchar* suffix = NULL;
	gboolean _tmp0_;
	const gchar* _tmp9_;
	const gchar* _tmp10_;
	const gchar* _tmp11_;
	gchar* _tmp12_ = NULL;
	gchar* file_path;
	const gchar* _tmp13_;
	gchar* _tmp14_ = NULL;
	gchar* path;
	GFile* _tmp15_ = NULL;
#line 99 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 99 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (type != NULL, NULL);
#line 99 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (item != NULL, NULL);
#line 105 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp0_ = simple;
#line 105 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_tmp0_) {
#line 624 "rygel-media-art-store.c"
		const gchar* _tmp1_;
		RygelMusicItem* _tmp2_;
		gchar* _tmp3_ = NULL;
		gchar* _tmp4_;
#line 106 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp1_ = type;
#line 106 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp2_ = item;
#line 106 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp3_ = rygel_media_art_store_get_simple_hash (self, _tmp1_, _tmp2_);
#line 106 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (hash);
#line 106 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		hash = _tmp3_;
#line 107 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp4_ = g_strdup ("jpg");
#line 107 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (suffix);
#line 107 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		suffix = _tmp4_;
#line 645 "rygel-media-art-store.c"
	} else {
		const gchar* _tmp5_;
		RygelMusicItem* _tmp6_;
		gchar* _tmp7_ = NULL;
		gchar* _tmp8_;
#line 109 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp5_ = type;
#line 109 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp6_ = item;
#line 109 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp7_ = rygel_media_art_store_get_hash (self, _tmp5_, _tmp6_);
#line 109 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (hash);
#line 109 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		hash = _tmp7_;
#line 110 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp8_ = g_strdup ("jpeg");
#line 110 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (suffix);
#line 110 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		suffix = _tmp8_;
#line 667 "rygel-media-art-store.c"
	}
#line 112 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp9_ = type;
#line 112 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp10_ = hash;
#line 112 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp11_ = suffix;
#line 112 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp12_ = g_strdup_printf ("%s-%s.%s", _tmp9_, _tmp10_, _tmp11_);
#line 112 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	file_path = _tmp12_;
#line 114 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp13_ = self->priv->directory;
#line 114 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp14_ = g_build_filename (_tmp13_, file_path, NULL);
#line 114 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	path = _tmp14_;
#line 116 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp15_ = g_file_new_for_path (path);
#line 116 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	result = _tmp15_;
#line 116 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (path);
#line 116 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (file_path);
#line 116 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (suffix);
#line 116 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (hash);
#line 116 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return result;
#line 699 "rygel-media-art-store.c"
}


static gchar string_get (const gchar* self, glong index) {
	gchar result = '\0';
	glong _tmp0_;
	gchar _tmp1_;
#line 951 "/opt/gnome2/share/vala-0.18/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, '\0');
#line 952 "/opt/gnome2/share/vala-0.18/vapi/glib-2.0.vapi"
	_tmp0_ = index;
#line 952 "/opt/gnome2/share/vala-0.18/vapi/glib-2.0.vapi"
	_tmp1_ = ((gchar*) self)[_tmp0_];
#line 952 "/opt/gnome2/share/vala-0.18/vapi/glib-2.0.vapi"
	result = _tmp1_;
#line 952 "/opt/gnome2/share/vala-0.18/vapi/glib-2.0.vapi"
	return result;
#line 717 "rygel-media-art-store.c"
}


static void _vala_array_add1 (GRegex*** array, int* length, int* size, GRegex* value) {
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if ((*length) == (*size)) {
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		*size = (*size) ? (2 * (*size)) : 4;
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		*array = g_renew (GRegex*, *array, (*size) + 1);
#line 728 "rygel-media-art-store.c"
	}
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	(*array)[(*length)++] = value;
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	(*array)[*length] = NULL;
#line 734 "rygel-media-art-store.c"
}


static RygelMediaArtStore* rygel_media_art_store_construct (GType object_type, GError** error) {
	RygelMediaArtStore * self = NULL;
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
	gchar* dir;
	const gchar* _tmp2_;
	GFile* _tmp3_ = NULL;
	GFile* file;
	GFile* _tmp4_;
	gboolean _tmp5_ = FALSE;
	const gchar* _tmp7_;
	gchar* _tmp8_;
	GError * _inner_error_ = NULL;
#line 119 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	self = (RygelMediaArtStore*) g_object_new (object_type, NULL);
#line 120 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp0_ = g_get_user_cache_dir ();
#line 120 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp1_ = g_build_filename (_tmp0_, "media-art", NULL);
#line 120 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	dir = _tmp1_;
#line 122 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp2_ = dir;
#line 122 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp3_ = g_file_new_for_path (_tmp2_);
#line 122 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	file = _tmp3_;
#line 124 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp4_ = file;
#line 124 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp5_ = g_file_query_exists (_tmp4_, NULL);
#line 124 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (!_tmp5_) {
#line 771 "rygel-media-art-store.c"
		const gchar* _tmp6_;
#line 125 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp6_ = dir;
#line 125 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		g_mkdir_with_parents (_tmp6_, 0750);
#line 777 "rygel-media-art-store.c"
	}
#line 128 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp7_ = dir;
#line 128 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp8_ = g_strdup (_tmp7_);
#line 128 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (self->priv->directory);
#line 128 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	self->priv->directory = _tmp8_;
#line 787 "rygel-media-art-store.c"
	{
		gchar* _tmp9_ = NULL;
		gchar* regex_string;
		const gchar* _tmp10_;
		gchar* _tmp11_ = NULL;
		gchar* _tmp12_;
		GRegex* _tmp13_;
		GRegex* _tmp14_;
		GRegex* _tmp15_;
		gchar* _tmp16_ = NULL;
		const gchar* _tmp17_;
		gchar* _tmp18_ = NULL;
		gchar* _tmp19_;
		GRegex* _tmp20_;
		GRegex* _tmp21_;
		GRegex* _tmp22_;
		GRegex* _tmp23_;
		GRegex* _tmp24_;
		GRegex** _tmp25_ = NULL;
#line 130 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp9_ = g_regex_escape_string (RYGEL_MEDIA_ART_STORE_invalid_chars, -1);
#line 130 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		regex_string = _tmp9_;
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp10_ = regex_string;
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp11_ = g_strdup_printf ("[%s]", _tmp10_);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp12_ = _tmp11_;
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp13_ = g_regex_new (_tmp12_, 0, 0, &_inner_error_);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp14_ = _tmp13_;
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (_tmp12_);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp15_ = _tmp14_;
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_inner_error_ != NULL) {
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (regex_string);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			if (_inner_error_->domain == G_REGEX_ERROR) {
#line 831 "rygel-media-art-store.c"
				goto __catch1_g_regex_error;
			}
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (regex_string);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_object_unref0 (file);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (dir);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_clear_error (&_inner_error_);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 846 "rygel-media-art-store.c"
		}
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_regex_unref0 (self->priv->char_remove_regex);
#line 131 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		self->priv->char_remove_regex = _tmp15_;
#line 132 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp16_ = g_regex_escape_string (RYGEL_MEDIA_ART_STORE_convert_chars, -1);
#line 132 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (regex_string);
#line 132 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		regex_string = _tmp16_;
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp17_ = regex_string;
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp18_ = g_strdup_printf ("[%s]", _tmp17_);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp19_ = _tmp18_;
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp20_ = g_regex_new (_tmp19_, 0, 0, &_inner_error_);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp21_ = _tmp20_;
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (_tmp19_);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp22_ = _tmp21_;
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_inner_error_ != NULL) {
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (regex_string);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			if (_inner_error_->domain == G_REGEX_ERROR) {
#line 878 "rygel-media-art-store.c"
				goto __catch1_g_regex_error;
			}
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (regex_string);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_object_unref0 (file);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (dir);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_clear_error (&_inner_error_);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 893 "rygel-media-art-store.c"
		}
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_regex_unref0 (self->priv->char_convert_regex);
#line 133 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		self->priv->char_convert_regex = _tmp22_;
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp23_ = g_regex_new ("\\s+", 0, 0, &_inner_error_);
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp24_ = _tmp23_;
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_inner_error_ != NULL) {
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (regex_string);
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			if (_inner_error_->domain == G_REGEX_ERROR) {
#line 909 "rygel-media-art-store.c"
				goto __catch1_g_regex_error;
			}
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (regex_string);
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_object_unref0 (file);
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (dir);
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_clear_error (&_inner_error_);
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 924 "rygel-media-art-store.c"
		}
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_regex_unref0 (self->priv->space_compress_regex);
#line 134 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		self->priv->space_compress_regex = _tmp24_;
#line 135 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp25_ = g_new0 (GRegex*, 0 + 1);
#line 135 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		self->priv->block_regexes = (_vala_array_free (self->priv->block_regexes, self->priv->block_regexes_length1, (GDestroyNotify) g_regex_unref), NULL);
#line 135 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		self->priv->block_regexes = _tmp25_;
#line 135 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		self->priv->block_regexes_length1 = 0;
#line 135 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		self->priv->_block_regexes_size_ = self->priv->block_regexes_length1;
#line 940 "rygel-media-art-store.c"
		{
			const gchar** block_collection = NULL;
			gint block_collection_length1 = 0;
			gint _block_collection_size_ = 0;
			gint block_it = 0;
#line 137 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			block_collection = RYGEL_MEDIA_ART_STORE_blocks;
#line 137 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			block_collection_length1 = G_N_ELEMENTS (RYGEL_MEDIA_ART_STORE_blocks);
#line 137 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			for (block_it = 0; block_it < G_N_ELEMENTS (RYGEL_MEDIA_ART_STORE_blocks); block_it = block_it + 1) {
#line 952 "rygel-media-art-store.c"
				const gchar* block = NULL;
#line 137 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				block = block_collection[block_it];
#line 956 "rygel-media-art-store.c"
				{
					const gchar* _tmp26_;
					gchar _tmp27_ = '\0';
					gchar* _tmp28_ = NULL;
					gchar* _tmp29_;
					gchar* _tmp30_ = NULL;
					gchar* _tmp31_;
					const gchar* _tmp32_;
					gchar _tmp33_ = '\0';
					gchar* _tmp34_ = NULL;
					gchar* _tmp35_;
					gchar* _tmp36_ = NULL;
					gchar* _tmp37_;
					const gchar* _tmp38_;
					gchar _tmp39_ = '\0';
					gchar* _tmp40_ = NULL;
					gchar* _tmp41_;
					gchar* _tmp42_ = NULL;
					gchar* _tmp43_;
					gchar* _tmp44_ = NULL;
					gchar* _tmp45_;
					gchar* block_re;
					const gchar* _tmp46_;
					GRegex* _tmp47_;
					GRegex* _tmp48_;
					GRegex** _tmp49_;
					gint _tmp49__length1;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp26_ = block;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp27_ = string_get (_tmp26_, (glong) 0);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp28_ = g_strdup_printf ("%C", _tmp27_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp29_ = _tmp28_;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp30_ = g_regex_escape_string (_tmp29_, -1);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp31_ = _tmp30_;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp32_ = block;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp33_ = string_get (_tmp32_, (glong) 1);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp34_ = g_strdup_printf ("%C", _tmp33_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp35_ = _tmp34_;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp36_ = g_regex_escape_string (_tmp35_, -1);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp37_ = _tmp36_;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp38_ = block;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp39_ = string_get (_tmp38_, (glong) 1);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp40_ = g_strdup_printf ("%C", _tmp39_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp41_ = _tmp40_;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp42_ = g_regex_escape_string (_tmp41_, -1);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp43_ = _tmp42_;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp44_ = g_strdup_printf (RYGEL_MEDIA_ART_STORE_block_pattern, _tmp31_, _tmp37_, _tmp43_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp45_ = _tmp44_;
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_free0 (_tmp43_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_free0 (_tmp41_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_free0 (_tmp37_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_free0 (_tmp35_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_free0 (_tmp31_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_free0 (_tmp29_);
#line 138 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					block_re = _tmp45_;
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp46_ = block_re;
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp47_ = g_regex_new (_tmp46_, 0, 0, &_inner_error_);
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp48_ = _tmp47_;
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					if (_inner_error_ != NULL) {
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						_g_free0 (block_re);
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						_g_free0 (regex_string);
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						if (_inner_error_->domain == G_REGEX_ERROR) {
#line 1052 "rygel-media-art-store.c"
							goto __catch1_g_regex_error;
						}
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						_g_free0 (block_re);
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						_g_free0 (regex_string);
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						_g_object_unref0 (file);
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						_g_free0 (dir);
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						g_clear_error (&_inner_error_);
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						return NULL;
#line 1069 "rygel-media-art-store.c"
					}
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp49_ = self->priv->block_regexes;
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp49__length1 = self->priv->block_regexes_length1;
#line 142 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_vala_array_add1 (&self->priv->block_regexes, &self->priv->block_regexes_length1, &self->priv->_block_regexes_size_, _tmp48_);
#line 137 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_free0 (block_re);
#line 1079 "rygel-media-art-store.c"
				}
			}
		}
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (regex_string);
#line 1085 "rygel-media-art-store.c"
	}
	goto __finally1;
	__catch1_g_regex_error:
	{
		GError* _error_ = NULL;
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_error_ = _inner_error_;
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_inner_error_ = NULL;
#line 145 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		g_assert_not_reached ();
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_error_free0 (_error_);
#line 1099 "rygel-media-art-store.c"
	}
	__finally1:
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_inner_error_ != NULL) {
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_inner_error_->domain == MEDIA_ART_STORE_ERROR) {
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_propagate_error (error, _inner_error_);
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_object_unref0 (file);
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (dir);
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_object_unref0 (self);
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 1116 "rygel-media-art-store.c"
		} else {
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_object_unref0 (file);
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (dir);
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_clear_error (&_inner_error_);
#line 129 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 1128 "rygel-media-art-store.c"
		}
	}
#line 119 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_object_unref0 (file);
#line 119 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (dir);
#line 119 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return self;
#line 1137 "rygel-media-art-store.c"
}


static RygelMediaArtStore* rygel_media_art_store_new (GError** error) {
#line 119 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return rygel_media_art_store_construct (RYGEL_TYPE_MEDIA_ART_STORE, error);
#line 1144 "rygel-media-art-store.c"
}


static gchar* rygel_media_art_store_get_simple_hash (RygelMediaArtStore* self, const gchar* type, RygelMusicItem* item) {
	gchar* result = NULL;
	gchar* hash = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	GQuark _tmp3_ = 0U;
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label0 = 0;
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label1 = 0;
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label2 = 0;
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label3 = 0;
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label4 = 0;
#line 149 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 149 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (type != NULL, NULL);
#line 149 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (item != NULL, NULL);
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp0_ = type;
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp1_ = _tmp0_;
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp3_ = (NULL == _tmp1_) ? 0 : g_quark_from_string (_tmp1_);
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if ((_tmp3_ == ((0 != _tmp2_label0) ? _tmp2_label0 : (_tmp2_label0 = g_quark_from_static_string ("artist")))) || (_tmp3_ == ((0 != _tmp2_label1) ? _tmp2_label1 : (_tmp2_label1 = g_quark_from_static_string ("radio"))))) {
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		switch (0) {
#line 1180 "rygel-media-art-store.c"
			default:
			{
				RygelMusicItem* _tmp4_;
				const gchar* _tmp5_;
				gchar* _tmp6_ = NULL;
#line 154 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp4_ = item;
#line 154 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp5_ = _tmp4_->artist;
#line 154 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp6_ = rygel_media_art_store_normalize_and_hash (self, _tmp5_, TRUE);
#line 154 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (hash);
#line 154 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				hash = _tmp6_;
#line 155 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				break;
#line 1198 "rygel-media-art-store.c"
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label2) ? _tmp2_label2 : (_tmp2_label2 = g_quark_from_static_string ("podcast")))) {
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		switch (0) {
#line 1204 "rygel-media-art-store.c"
			default:
			{
				RygelMusicItem* _tmp7_;
				const gchar* _tmp8_;
				gchar* _tmp9_ = NULL;
#line 157 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp7_ = item;
#line 157 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp8_ = ((RygelMediaItem*) _tmp7_)->title;
#line 157 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp9_ = rygel_media_art_store_normalize_and_hash (self, _tmp8_, TRUE);
#line 157 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (hash);
#line 157 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				hash = _tmp9_;
#line 158 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				break;
#line 1222 "rygel-media-art-store.c"
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label3) ? _tmp2_label3 : (_tmp2_label3 = g_quark_from_static_string ("album")))) {
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		switch (0) {
#line 1228 "rygel-media-art-store.c"
			default:
			{
				RygelMusicItem* _tmp10_;
				const gchar* _tmp11_;
				gchar* _tmp12_;
				gchar* _tmp13_;
				RygelMusicItem* _tmp14_;
				const gchar* _tmp15_;
				gchar* _tmp16_;
				gchar* _tmp17_;
				gchar* _tmp18_ = NULL;
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp10_ = item;
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp11_ = _tmp10_->artist;
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp12_ = g_strconcat (_tmp11_, "\t", NULL);
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp13_ = _tmp12_;
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp14_ = item;
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp15_ = _tmp14_->album;
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp16_ = g_strconcat (_tmp13_, _tmp15_, NULL);
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp17_ = _tmp16_;
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp18_ = rygel_media_art_store_normalize_and_hash (self, _tmp17_, TRUE);
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (hash);
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				hash = _tmp18_;
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (_tmp17_);
#line 160 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (_tmp13_);
#line 162 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				break;
#line 1268 "rygel-media-art-store.c"
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label4) ? _tmp2_label4 : (_tmp2_label4 = g_quark_from_static_string ("track")))) {
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		switch (0) {
#line 1274 "rygel-media-art-store.c"
			default:
			{
				RygelMusicItem* _tmp19_;
				const gchar* _tmp20_;
				gchar* _tmp21_;
				gchar* _tmp22_;
				RygelMusicItem* _tmp23_;
				const gchar* _tmp24_;
				gchar* _tmp25_;
				gchar* _tmp26_;
				gchar* _tmp27_;
				gchar* _tmp28_;
				RygelMusicItem* _tmp29_;
				const gchar* _tmp30_;
				gchar* _tmp31_;
				gchar* _tmp32_;
				gchar* _tmp33_ = NULL;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp19_ = item;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp20_ = _tmp19_->artist;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp21_ = g_strconcat (_tmp20_, "\t", NULL);
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp22_ = _tmp21_;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp23_ = item;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp24_ = _tmp23_->album;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp25_ = g_strconcat (_tmp22_, _tmp24_, NULL);
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp26_ = _tmp25_;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp27_ = g_strconcat (_tmp26_, "\t", NULL);
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp28_ = _tmp27_;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp29_ = item;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp30_ = ((RygelMediaItem*) _tmp29_)->title;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp31_ = g_strconcat (_tmp28_, _tmp30_, NULL);
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp32_ = _tmp31_;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp33_ = rygel_media_art_store_normalize_and_hash (self, _tmp32_, TRUE);
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (hash);
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				hash = _tmp33_;
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (_tmp32_);
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (_tmp28_);
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (_tmp26_);
#line 164 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (_tmp22_);
#line 167 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				break;
#line 1336 "rygel-media-art-store.c"
			}
		}
	} else {
#line 151 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		switch (0) {
#line 1342 "rygel-media-art-store.c"
			default:
			{
#line 169 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				g_assert_not_reached ();
#line 1347 "rygel-media-art-store.c"
			}
		}
	}
#line 172 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	result = hash;
#line 172 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return result;
#line 1355 "rygel-media-art-store.c"
}


static gchar* rygel_media_art_store_get_hash (RygelMediaArtStore* self, const gchar* type, RygelMusicItem* item) {
	gchar* result = NULL;
	gchar* b;
	gchar* c;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	GQuark _tmp3_ = 0U;
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label0 = 0;
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label1 = 0;
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label2 = 0;
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label3 = 0;
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	static GQuark _tmp2_label4 = 0;
#line 1376 "rygel-media-art-store.c"
	const gchar* _tmp28_;
	const gchar* _tmp29_;
	gchar* _tmp30_ = NULL;
#line 175 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 175 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (type != NULL, NULL);
#line 175 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (item != NULL, NULL);
#line 176 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	b = NULL;
#line 176 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	c = NULL;
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp0_ = type;
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp1_ = _tmp0_;
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp3_ = (NULL == _tmp1_) ? 0 : g_quark_from_string (_tmp1_);
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_tmp3_ == ((0 != _tmp2_label0) ? _tmp2_label0 : (_tmp2_label0 = g_quark_from_static_string ("track")))) {
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		switch (0) {
#line 1400 "rygel-media-art-store.c"
			default:
			{
				RygelMusicItem* _tmp4_;
				const gchar* _tmp5_;
				gchar* _tmp6_ = NULL;
				gchar* _tmp7_;
				gchar* _tmp8_;
				gchar* _tmp9_;
				RygelMusicItem* _tmp10_;
				const gchar* _tmp11_;
				gchar* _tmp12_ = NULL;
				gchar* _tmp13_;
				gchar* _tmp14_;
				RygelMusicItem* _tmp15_;
				const gchar* _tmp16_;
				gchar* _tmp17_ = NULL;
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp4_ = item;
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp5_ = _tmp4_->artist;
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp6_ = rygel_media_art_store_normalize_and_hash (self, _tmp5_, FALSE);
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp7_ = _tmp6_;
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp8_ = g_strconcat (_tmp7_, "-", NULL);
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp9_ = _tmp8_;
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp10_ = item;
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp11_ = _tmp10_->album;
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp12_ = rygel_media_art_store_normalize_and_hash (self, _tmp11_, FALSE);
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp13_ = _tmp12_;
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp14_ = g_strconcat (_tmp9_, _tmp13_, NULL);
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (b);
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				b = _tmp14_;
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (_tmp13_);
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (_tmp9_);
#line 179 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (_tmp7_);
#line 181 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp15_ = item;
#line 181 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp16_ = ((RygelMediaItem*) _tmp15_)->title;
#line 181 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp17_ = rygel_media_art_store_normalize_and_hash (self, _tmp16_, FALSE);
#line 181 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (c);
#line 181 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				c = _tmp17_;
#line 182 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				break;
#line 1461 "rygel-media-art-store.c"
			}
		}
	} else if ((_tmp3_ == ((0 != _tmp2_label1) ? _tmp2_label1 : (_tmp2_label1 = g_quark_from_static_string ("album")))) || (_tmp3_ == ((0 != _tmp2_label2) ? _tmp2_label2 : (_tmp2_label2 = g_quark_from_static_string ("artist"))))) {
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		switch (0) {
#line 1467 "rygel-media-art-store.c"
			default:
			{
				RygelMusicItem* _tmp18_;
				const gchar* _tmp19_;
				gchar* _tmp20_ = NULL;
				RygelMusicItem* _tmp21_;
				const gchar* _tmp22_;
				gchar* _tmp23_ = NULL;
#line 185 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp18_ = item;
#line 185 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp19_ = _tmp18_->artist;
#line 185 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp20_ = rygel_media_art_store_normalize_and_hash (self, _tmp19_, FALSE);
#line 185 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (b);
#line 185 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				b = _tmp20_;
#line 186 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp21_ = item;
#line 186 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp22_ = _tmp21_->album;
#line 186 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp23_ = rygel_media_art_store_normalize_and_hash (self, _tmp22_, FALSE);
#line 186 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (c);
#line 186 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				c = _tmp23_;
#line 187 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				break;
#line 1498 "rygel-media-art-store.c"
			}
		}
	} else if ((_tmp3_ == ((0 != _tmp2_label3) ? _tmp2_label3 : (_tmp2_label3 = g_quark_from_static_string ("radio")))) || (_tmp3_ == ((0 != _tmp2_label4) ? _tmp2_label4 : (_tmp2_label4 = g_quark_from_static_string ("podcast"))))) {
#line 177 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		switch (0) {
#line 1504 "rygel-media-art-store.c"
			default:
			{
				RygelMusicItem* _tmp24_;
				const gchar* _tmp25_;
				gchar* _tmp26_ = NULL;
				gchar* _tmp27_;
#line 190 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp24_ = item;
#line 190 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp25_ = ((RygelMediaItem*) _tmp24_)->title;
#line 190 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp26_ = rygel_media_art_store_normalize_and_hash (self, _tmp25_, FALSE);
#line 190 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (b);
#line 190 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				b = _tmp26_;
#line 191 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp27_ = g_strdup (RYGEL_MEDIA_ART_STORE_PLACEHOLDER_HASH);
#line 191 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_g_free0 (c);
#line 191 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				c = _tmp27_;
#line 192 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				break;
#line 1529 "rygel-media-art-store.c"
			}
		}
	}
#line 195 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp28_ = b;
#line 195 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp29_ = c;
#line 195 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp30_ = g_strdup_printf ("%s-%s", _tmp28_, _tmp29_);
#line 195 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	result = _tmp30_;
#line 195 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (c);
#line 195 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (b);
#line 195 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return result;
#line 1547 "rygel-media-art-store.c"
}


static gchar* rygel_media_art_store_normalize_and_hash (RygelMediaArtStore* self, const gchar* input, gboolean utf8_only) {
	gchar* result = NULL;
	gchar* _tmp0_;
	gchar* normalized;
	gboolean _tmp1_ = FALSE;
	const gchar* _tmp2_;
	gboolean _tmp4_;
	const gchar* _tmp14_;
	gchar* _tmp15_ = NULL;
#line 198 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 199 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp0_ = g_strdup (" ");
#line 199 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	normalized = _tmp0_;
#line 200 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp2_ = input;
#line 200 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_tmp2_ != NULL) {
#line 1570 "rygel-media-art-store.c"
		const gchar* _tmp3_;
#line 200 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp3_ = input;
#line 200 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp1_ = g_strcmp0 (_tmp3_, "") != 0;
#line 1576 "rygel-media-art-store.c"
	} else {
#line 200 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp1_ = FALSE;
#line 1580 "rygel-media-art-store.c"
	}
#line 200 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp4_ = _tmp1_;
#line 200 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	if (_tmp4_) {
#line 1586 "rygel-media-art-store.c"
		gboolean _tmp5_;
		const gchar* _tmp12_;
		gchar* _tmp13_ = NULL;
#line 201 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp5_ = utf8_only;
#line 201 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_tmp5_) {
#line 1594 "rygel-media-art-store.c"
			const gchar* _tmp6_;
			gchar* _tmp7_;
#line 202 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp6_ = input;
#line 202 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp7_ = g_strdup (_tmp6_);
#line 202 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (normalized);
#line 202 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			normalized = _tmp7_;
#line 1605 "rygel-media-art-store.c"
		} else {
			const gchar* _tmp8_;
			gchar* _tmp9_ = NULL;
			const gchar* _tmp10_;
			gchar* _tmp11_ = NULL;
#line 204 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp8_ = input;
#line 204 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp9_ = rygel_media_art_store_strip_invalid_entities (self, _tmp8_);
#line 204 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (normalized);
#line 204 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			normalized = _tmp9_;
#line 205 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp10_ = normalized;
#line 205 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_tmp11_ = g_utf8_strdown (_tmp10_, (gssize) (-1));
#line 205 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (normalized);
#line 205 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			normalized = _tmp11_;
#line 1627 "rygel-media-art-store.c"
		}
#line 207 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp12_ = normalized;
#line 207 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp13_ = g_utf8_normalize (_tmp12_, (gssize) (-1), G_NORMALIZE_ALL);
#line 207 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (normalized);
#line 207 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		normalized = _tmp13_;
#line 1637 "rygel-media-art-store.c"
	}
#line 210 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp14_ = normalized;
#line 210 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp15_ = g_compute_checksum_for_string (G_CHECKSUM_MD5, _tmp14_, (gsize) (-1));
#line 210 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	result = _tmp15_;
#line 210 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (normalized);
#line 210 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return result;
#line 1649 "rygel-media-art-store.c"
}


static gpointer _g_regex_ref0 (gpointer self) {
#line 219 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return self ? g_regex_ref (self) : NULL;
#line 1656 "rygel-media-art-store.c"
}


static gchar* rygel_media_art_store_strip_invalid_entities (RygelMediaArtStore* self, const gchar* original) {
	gchar* result = NULL;
	gchar* p = NULL;
	const gchar* _tmp0_;
	gchar* _tmp1_;
	GError * _inner_error_ = NULL;
#line 213 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 213 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_return_val_if_fail (original != NULL, NULL);
#line 216 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp0_ = original;
#line 216 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_tmp1_ = g_strdup (_tmp0_);
#line 216 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (p);
#line 216 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	p = _tmp1_;
#line 1678 "rygel-media-art-store.c"
	{
		GRegex** _tmp2_;
		gint _tmp2__length1;
		GRegex* _tmp8_;
		const gchar* _tmp9_;
		gchar* _tmp10_ = NULL;
		gchar* _tmp11_;
		GRegex* _tmp12_;
		const gchar* _tmp13_;
		gchar* _tmp14_ = NULL;
		gchar* _tmp15_;
		GRegex* _tmp16_;
		const gchar* _tmp17_;
		gchar* _tmp18_ = NULL;
		gchar* _tmp19_;
#line 219 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp2_ = self->priv->block_regexes;
#line 219 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp2__length1 = self->priv->block_regexes_length1;
#line 1698 "rygel-media-art-store.c"
		{
			GRegex** re_collection = NULL;
			gint re_collection_length1 = 0;
			gint _re_collection_size_ = 0;
			gint re_it = 0;
#line 219 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			re_collection = _tmp2_;
#line 219 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			re_collection_length1 = _tmp2__length1;
#line 219 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			for (re_it = 0; re_it < _tmp2__length1; re_it = re_it + 1) {
#line 1710 "rygel-media-art-store.c"
				GRegex* _tmp3_;
				GRegex* re = NULL;
#line 219 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				_tmp3_ = _g_regex_ref0 (re_collection[re_it]);
#line 219 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
				re = _tmp3_;
#line 1717 "rygel-media-art-store.c"
				{
					GRegex* _tmp4_;
					const gchar* _tmp5_;
					gchar* _tmp6_ = NULL;
					gchar* _tmp7_;
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp4_ = re;
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp5_ = p;
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp6_ = g_regex_replace_literal (_tmp4_, _tmp5_, (gssize) (-1), 0, "", 0, &_inner_error_);
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_tmp7_ = _tmp6_;
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					if (_inner_error_ != NULL) {
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						_g_regex_unref0 (re);
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						if (_inner_error_->domain == G_REGEX_ERROR) {
#line 1737 "rygel-media-art-store.c"
							goto __catch2_g_regex_error;
						}
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						_g_regex_unref0 (re);
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						_g_free0 (p);
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						g_clear_error (&_inner_error_);
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
						return NULL;
#line 1750 "rygel-media-art-store.c"
					}
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_free0 (p);
#line 220 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					p = _tmp7_;
#line 219 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
					_g_regex_unref0 (re);
#line 1758 "rygel-media-art-store.c"
				}
			}
		}
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp8_ = self->priv->char_remove_regex;
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp9_ = p;
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp10_ = g_regex_replace_literal (_tmp8_, _tmp9_, (gssize) (-1), 0, "", 0, &_inner_error_);
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp11_ = _tmp10_;
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_inner_error_ != NULL) {
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			if (_inner_error_->domain == G_REGEX_ERROR) {
#line 1774 "rygel-media-art-store.c"
				goto __catch2_g_regex_error;
			}
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (p);
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_clear_error (&_inner_error_);
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 1785 "rygel-media-art-store.c"
		}
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (p);
#line 223 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		p = _tmp11_;
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp12_ = self->priv->char_convert_regex;
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp13_ = p;
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp14_ = g_regex_replace_literal (_tmp12_, _tmp13_, (gssize) (-1), 0, " ", 0, &_inner_error_);
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp15_ = _tmp14_;
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_inner_error_ != NULL) {
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			if (_inner_error_->domain == G_REGEX_ERROR) {
#line 1803 "rygel-media-art-store.c"
				goto __catch2_g_regex_error;
			}
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (p);
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_clear_error (&_inner_error_);
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 1814 "rygel-media-art-store.c"
		}
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (p);
#line 224 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		p = _tmp15_;
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp16_ = self->priv->space_compress_regex;
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp17_ = p;
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp18_ = g_regex_replace_literal (_tmp16_, _tmp17_, (gssize) (-1), 0, " ", 0, &_inner_error_);
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_tmp19_ = _tmp18_;
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		if (_inner_error_ != NULL) {
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			if (_inner_error_->domain == G_REGEX_ERROR) {
#line 1832 "rygel-media-art-store.c"
				goto __catch2_g_regex_error;
			}
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			_g_free0 (p);
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			g_clear_error (&_inner_error_);
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
			return NULL;
#line 1843 "rygel-media-art-store.c"
		}
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_free0 (p);
#line 225 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		p = _tmp19_;
#line 227 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		result = p;
#line 227 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		return result;
#line 1853 "rygel-media-art-store.c"
	}
	goto __finally2;
	__catch2_g_regex_error:
	{
		GError* _error_ = NULL;
#line 218 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_error_ = _inner_error_;
#line 218 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_inner_error_ = NULL;
#line 229 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		g_assert_not_reached ();
#line 218 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
		_g_error_free0 (_error_);
#line 1867 "rygel-media-art-store.c"
	}
	__finally2:
#line 218 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (p);
#line 218 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 218 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_clear_error (&_inner_error_);
#line 218 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	return NULL;
#line 1878 "rygel-media-art-store.c"
}


static void rygel_media_art_store_class_init (RygelMediaArtStoreClass * klass) {
#line 28 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	rygel_media_art_store_parent_class = g_type_class_peek_parent (klass);
#line 28 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	g_type_class_add_private (klass, sizeof (RygelMediaArtStorePrivate));
#line 28 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	G_OBJECT_CLASS (klass)->finalize = rygel_media_art_store_finalize;
#line 1889 "rygel-media-art-store.c"
}


static void rygel_media_art_store_instance_init (RygelMediaArtStore * self) {
#line 28 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	self->priv = RYGEL_MEDIA_ART_STORE_GET_PRIVATE (self);
#line 1896 "rygel-media-art-store.c"
}


static void rygel_media_art_store_finalize (GObject* obj) {
	RygelMediaArtStore * self;
#line 28 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, RYGEL_TYPE_MEDIA_ART_STORE, RygelMediaArtStore);
#line 36 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_regex_unref0 (self->priv->char_remove_regex);
#line 37 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_regex_unref0 (self->priv->char_convert_regex);
#line 38 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_regex_unref0 (self->priv->space_compress_regex);
#line 39 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	self->priv->block_regexes = (_vala_array_free (self->priv->block_regexes, self->priv->block_regexes_length1, (GDestroyNotify) g_regex_unref), NULL);
#line 41 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	_g_free0 (self->priv->directory);
#line 28 "/home/jens/Source/rygel/tests/rygel-media-art-store.vala"
	G_OBJECT_CLASS (rygel_media_art_store_parent_class)->finalize (obj);
#line 1916 "rygel-media-art-store.c"
}


GType rygel_media_art_store_get_type (void) {
	static volatile gsize rygel_media_art_store_type_id__volatile = 0;
	if (g_once_init_enter (&rygel_media_art_store_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (RygelMediaArtStoreClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) rygel_media_art_store_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (RygelMediaArtStore), 0, (GInstanceInitFunc) rygel_media_art_store_instance_init, NULL };
		GType rygel_media_art_store_type_id;
		rygel_media_art_store_type_id = g_type_register_static (G_TYPE_OBJECT, "RygelMediaArtStore", &g_define_type_info, 0);
		g_once_init_leave (&rygel_media_art_store_type_id__volatile, rygel_media_art_store_type_id);
	}
	return rygel_media_art_store_type_id__volatile;
}


static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) {
	if ((array != NULL) && (destroy_func != NULL)) {
		int i;
		for (i = 0; i < array_length; i = i + 1) {
			if (((gpointer*) array)[i] != NULL) {
				destroy_func (((gpointer*) array)[i]);
			}
		}
	}
}


static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) {
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}



