/* midori-paths.c generated by valac 0.38.8, the Vala compiler
 * generated from midori-paths.vala, do not modify */

/*
 Copyright (C) 2012 Christian Dywan <christian@twotoasts.de>

 This library 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.1 of the License, or (at your option) any later version.

 See the file COPYING for the full license text.
*/

#include <glib.h>
#include <glib-object.h>
#include <stdlib.h>
#include <string.h>
#include <gmodule.h>
#include <gtk/gtk.h>
#include "webkit/webkit.h"
#include <stdio.h>
#include <unistd.h>
#include <glib/gstdio.h>
#include <gio/gio.h>
#include <gdk-pixbuf/gdk-pixbuf.h>


#define MIDORI_TYPE_RUNTIME_MODE (midori_runtime_mode_get_type ())
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_dir_close0(var) ((var == NULL) ? NULL : (var = (g_dir_close (var), NULL)))
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_regex_unref0(var) ((var == NULL) ? NULL : (var = (g_regex_unref (var), NULL)))
#define _vala_assert(expr, msg) if G_LIKELY (expr) ; else g_assertion_message_expr (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, msg);
#define _vala_return_if_fail(expr, msg) if G_LIKELY (expr) ; else { g_return_if_fail_warning (G_LOG_DOMAIN, G_STRFUNC, msg); return; }
#define _vala_return_val_if_fail(expr, msg, val) if G_LIKELY (expr) ; else { g_return_if_fail_warning (G_LOG_DOMAIN, G_STRFUNC, msg); return val; }
#define _vala_warn_if_fail(expr, msg) if G_LIKELY (expr) ; else g_warn_message (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, msg);

typedef enum  {
	MIDORI_RUNTIME_MODE_UNDEFINED,
	MIDORI_RUNTIME_MODE_NORMAL,
	MIDORI_RUNTIME_MODE_APP,
	MIDORI_RUNTIME_MODE_PRIVATE,
	MIDORI_RUNTIME_MODE_PORTABLE
} MidoriRuntimeMode;


extern gchar* midori_paths_exec_path;
gchar* midori_paths_exec_path = NULL;
extern gchar** midori_paths_command_line;
extern gint midori_paths_command_line_length1;
gchar** midori_paths_command_line = NULL;
gint midori_paths_command_line_length1 = 0;
static gint _midori_paths_command_line_size_ = 0;
extern gchar* midori_paths_runtime_dir;
gchar* midori_paths_runtime_dir = NULL;
extern MidoriRuntimeMode midori_paths_mode;
MidoriRuntimeMode midori_paths_mode = MIDORI_RUNTIME_MODE_UNDEFINED;
extern gchar* midori_paths_config_dir;
gchar* midori_paths_config_dir = NULL;
extern gchar* midori_paths_readonly_dir;
gchar* midori_paths_readonly_dir = NULL;
extern gchar* midori_paths_cache_dir;
gchar* midori_paths_cache_dir = NULL;
extern gchar* midori_paths_cache_dir_for_reading;
gchar* midori_paths_cache_dir_for_reading = NULL;
extern gchar* midori_paths_user_data_dir;
gchar* midori_paths_user_data_dir = NULL;
extern gchar* midori_paths_user_data_dir_for_reading;
gchar* midori_paths_user_data_dir_for_reading = NULL;
extern gchar* midori_paths_tmp_dir;
gchar* midori_paths_tmp_dir = NULL;

#define MODULE_PREFIX "lib"
#define MODULE_SUFFIX "." G_MODULE_SUFFIX
GType midori_runtime_mode_get_type (void) G_GNUC_CONST;
void midori_paths_test_reset_runtime_mode (void);
gchar* midori_paths_get_config_dir_for_reading (void);
gchar* midori_paths_get_config_filename_for_reading (const gchar* filename);
gboolean midori_paths_is_readonly (void);
MidoriRuntimeMode midori_paths_get_runtime_mode (void);
const gchar* midori_paths_get_runtime_dir (void);
void midori_paths_mkdir_with_parents (const gchar* path, gint mode);
void midori_paths_init (MidoriRuntimeMode new_mode, const gchar* config);
void midori_paths_remove_path (const gchar* path);
const gchar* midori_paths_get_config_dir_for_writing (void);
gchar* midori_paths_get_extension_config_dir (const gchar* extension);
gchar* midori_paths_get_extension_preset_filename (const gchar* extension, const gchar* filename);
gchar* midori_paths_get_preset_filename (const gchar* folder, const gchar* filename);
gchar* midori_paths_get_config_filename_for_writing (const gchar* filename);
const gchar* midori_paths_get_cache_dir (void);
const gchar* midori_paths_get_user_data_dir (void);
const gchar* midori_paths_get_user_data_dir_for_reading (void);
const gchar* midori_paths_get_cache_dir_for_reading (void);
const gchar* midori_paths_get_tmp_dir (void);
gchar* midori_paths_make_tmp_dir (const gchar* tmpl);
void midori_paths_init_exec_path (gchar** new_command_line, int new_command_line_length1);
static gchar** _vala_array_dup1 (gchar** self, int length);
gchar* midori_paths_get_command_line_str (gboolean for_display);
gchar* midori_paths_get_res_filename (const gchar* filename);
gchar* midori_paths_get_lib_path (const gchar* package);
gchar** midori_paths_get_command_line (int* result_length1);
gchar* midori_paths_build_folder (const gchar* folder, const gchar* middle, const gchar* filename);
gchar* midori_paths_get_data_filename (const gchar* filename, gboolean res);
void midori_paths_clear_icons (void);
GdkPixbuf* midori_paths_get_icon (const gchar* uri, GtkWidget* widget);
gboolean midori_uri_is_resource (const gchar* uri);
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 gint _vala_array_length (gpointer array);


GType midori_runtime_mode_get_type (void) {
	static volatile gsize midori_runtime_mode_type_id__volatile = 0;
	if (g_once_init_enter (&midori_runtime_mode_type_id__volatile)) {
		static const GEnumValue values[] = {{MIDORI_RUNTIME_MODE_UNDEFINED, "MIDORI_RUNTIME_MODE_UNDEFINED", "undefined"}, {MIDORI_RUNTIME_MODE_NORMAL, "MIDORI_RUNTIME_MODE_NORMAL", "normal"}, {MIDORI_RUNTIME_MODE_APP, "MIDORI_RUNTIME_MODE_APP", "app"}, {MIDORI_RUNTIME_MODE_PRIVATE, "MIDORI_RUNTIME_MODE_PRIVATE", "private"}, {MIDORI_RUNTIME_MODE_PORTABLE, "MIDORI_RUNTIME_MODE_PORTABLE", "portable"}, {0, NULL, NULL}};
		GType midori_runtime_mode_type_id;
		midori_runtime_mode_type_id = g_enum_register_static ("MidoriRuntimeMode", values);
		g_once_init_leave (&midori_runtime_mode_type_id__volatile, midori_runtime_mode_type_id);
	}
	return midori_runtime_mode_type_id__volatile;
}


void midori_paths_test_reset_runtime_mode (void) {
#line 51 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_mode = MIDORI_RUNTIME_MODE_UNDEFINED;
#line 130 "midori-paths.c"
}


gchar* midori_paths_get_config_dir_for_reading (void) {
	gchar* result = NULL;
	MidoriRuntimeMode _tmp0_;
	const gchar* _tmp1_ = NULL;
	const gchar* _tmp2_;
	gchar* _tmp4_;
#line 56 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_mode;
#line 56 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != MIDORI_RUNTIME_MODE_UNDEFINED, "mode != RuntimeMode.UNDEFINED");
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = midori_paths_readonly_dir;
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = _tmp2_;
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp1_ == NULL) {
#line 150 "midori-paths.c"
		const gchar* _tmp3_;
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = midori_paths_config_dir;
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp1_ = _tmp3_;
#line 156 "midori-paths.c"
	}
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp4_ = g_strdup (_tmp1_);
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp4_;
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 164 "midori-paths.c"
}


gchar* midori_paths_get_config_filename_for_reading (const gchar* filename) {
	gchar* result = NULL;
	MidoriRuntimeMode _tmp0_;
	const gchar* _tmp1_ = NULL;
	const gchar* _tmp2_;
	const gchar* _tmp4_;
	gchar* _tmp5_;
#line 62 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (filename != NULL, NULL);
#line 63 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_mode;
#line 63 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != MIDORI_RUNTIME_MODE_UNDEFINED, "mode != RuntimeMode.UNDEFINED");
#line 65 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = midori_paths_readonly_dir;
#line 65 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = _tmp2_;
#line 65 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp1_ == NULL) {
#line 187 "midori-paths.c"
		const gchar* _tmp3_;
#line 65 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = midori_paths_config_dir;
#line 65 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp1_ = _tmp3_;
#line 193 "midori-paths.c"
	}
#line 64 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp4_ = filename;
#line 64 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp5_ = g_build_path (G_DIR_SEPARATOR_S, _tmp1_, _tmp4_, NULL);
#line 64 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp5_;
#line 64 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 203 "midori-paths.c"
}


gboolean midori_paths_is_readonly (void) {
	gboolean result = FALSE;
	MidoriRuntimeMode _tmp0_;
	const gchar* _tmp1_;
#line 69 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_mode;
#line 69 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != MIDORI_RUNTIME_MODE_UNDEFINED, "mode != RuntimeMode.UNDEFINED");
#line 70 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_readonly_dir;
#line 70 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp1_ != NULL;
#line 70 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 221 "midori-paths.c"
}


MidoriRuntimeMode midori_paths_get_runtime_mode (void) {
	MidoriRuntimeMode result = 0;
	MidoriRuntimeMode _tmp0_;
	MidoriRuntimeMode _tmp1_;
#line 74 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_mode;
#line 74 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != MIDORI_RUNTIME_MODE_UNDEFINED, "mode != RuntimeMode.UNDEFINED");
#line 75 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_mode;
#line 75 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp1_;
#line 75 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 239 "midori-paths.c"
}


const gchar* midori_paths_get_runtime_dir (void) {
	const gchar* result = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	gboolean _tmp4_ = FALSE;
	const gchar* _tmp5_;
	const gchar* _tmp14_;
	gchar* _tmp15_;
	const gchar* _tmp16_;
	const gchar* _tmp17_;
#line 79 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_runtime_dir;
#line 79 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp0_ != NULL) {
#line 258 "midori-paths.c"
		const gchar* _tmp1_;
#line 80 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp1_ = midori_paths_runtime_dir;
#line 80 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = _tmp1_;
#line 80 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 266 "midori-paths.c"
	}
#line 87 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = g_getenv ("XDG_RUNTIME_DIR");
#line 87 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = g_strdup (_tmp2_);
#line 87 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (midori_paths_runtime_dir);
#line 87 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_runtime_dir = _tmp3_;
#line 88 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp5_ = midori_paths_runtime_dir;
#line 88 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp5_ == NULL) {
#line 88 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = TRUE;
#line 282 "midori-paths.c"
	} else {
		const gchar* _tmp6_;
#line 88 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp6_ = midori_paths_runtime_dir;
#line 88 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = g_strcmp0 (_tmp6_, "") == 0;
#line 289 "midori-paths.c"
	}
#line 88 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp4_) {
#line 293 "midori-paths.c"
		const gchar* _tmp7_;
		const gchar* _tmp8_;
		gchar* _tmp9_;
		gchar* _tmp10_;
		gchar* _tmp11_;
		const gchar* _tmp12_;
		const gchar* _tmp13_;
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp7_ = g_get_tmp_dir ();
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp8_ = g_get_user_name ();
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp9_ = g_strconcat (PACKAGE_NAME "-", _tmp8_, NULL);
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp10_ = _tmp9_;
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp11_ = g_build_path (G_DIR_SEPARATOR_S, _tmp7_, _tmp10_, NULL);
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (midori_paths_runtime_dir);
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		midori_paths_runtime_dir = _tmp11_;
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp10_);
#line 91 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp12_ = midori_paths_runtime_dir;
#line 91 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		midori_paths_mkdir_with_parents (_tmp12_, 0700);
#line 92 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp13_ = midori_paths_runtime_dir;
#line 92 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = _tmp13_;
#line 92 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 327 "midori-paths.c"
	}
#line 95 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp14_ = midori_paths_runtime_dir;
#line 95 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp15_ = g_build_path (G_DIR_SEPARATOR_S, _tmp14_, PACKAGE_NAME, NULL);
#line 95 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (midori_paths_runtime_dir);
#line 95 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_runtime_dir = _tmp15_;
#line 96 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp16_ = midori_paths_runtime_dir;
#line 96 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_mkdir_with_parents (_tmp16_, 0700);
#line 97 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp17_ = midori_paths_runtime_dir;
#line 97 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp17_;
#line 97 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 347 "midori-paths.c"
}


void midori_paths_init (MidoriRuntimeMode new_mode, const gchar* config) {
	MidoriRuntimeMode _tmp0_;
	MidoriRuntimeMode _tmp1_;
	MidoriRuntimeMode _tmp2_;
	gboolean _tmp3_ = FALSE;
	MidoriRuntimeMode _tmp4_;
	MidoriRuntimeMode _tmp7_;
	const gchar* _tmp79_;
	GtkIconTheme* _tmp85_;
	const gchar* _tmp86_;
	GCompareFunc _tmp87_;
	const gchar* _tmp88_;
	gint _tmp89_;
#line 101 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_mode;
#line 101 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ == MIDORI_RUNTIME_MODE_UNDEFINED, "mode == RuntimeMode.UNDEFINED");
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = new_mode;
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp1_ != MIDORI_RUNTIME_MODE_UNDEFINED, "new_mode != RuntimeMode.UNDEFINED");
#line 103 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = new_mode;
#line 103 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_mode = _tmp2_;
#line 104 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp4_ = midori_paths_mode;
#line 104 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp4_ == MIDORI_RUNTIME_MODE_PORTABLE) {
#line 104 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = TRUE;
#line 382 "midori-paths.c"
	} else {
		MidoriRuntimeMode _tmp5_;
#line 104 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp5_ = midori_paths_mode;
#line 104 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = _tmp5_ == MIDORI_RUNTIME_MODE_PRIVATE;
#line 389 "midori-paths.c"
	}
#line 104 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp3_) {
#line 393 "midori-paths.c"
		GtkSettings* _tmp6_;
#line 105 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp6_ = gtk_settings_get_default ();
#line 105 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		g_object_set (_tmp6_, "gtk-recent-files-max-age", 0, NULL);
#line 399 "midori-paths.c"
	}
#line 106 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp7_ = midori_paths_mode;
#line 106 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp7_ == MIDORI_RUNTIME_MODE_PORTABLE) {
#line 405 "midori-paths.c"
		const gchar* _tmp8_;
		gchar* _tmp9_;
		const gchar* _tmp10_;
		gchar* _tmp11_;
		const gchar* _tmp12_;
		gchar* _tmp13_;
		const gchar* _tmp14_;
		gchar* _tmp15_;
#line 107 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp8_ = midori_paths_exec_path;
#line 107 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp9_ = g_build_path (G_DIR_SEPARATOR_S, _tmp8_, "profile", "config", NULL);
#line 107 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (midori_paths_config_dir);
#line 107 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		midori_paths_config_dir = _tmp9_;
#line 109 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp10_ = midori_paths_exec_path;
#line 109 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp11_ = g_build_path (G_DIR_SEPARATOR_S, _tmp10_, "profile", "cache", NULL);
#line 109 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (midori_paths_cache_dir);
#line 109 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		midori_paths_cache_dir = _tmp11_;
#line 111 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp12_ = midori_paths_exec_path;
#line 111 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp13_ = g_build_path (G_DIR_SEPARATOR_S, _tmp12_, "profile", "misc", NULL);
#line 111 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (midori_paths_user_data_dir);
#line 111 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		midori_paths_user_data_dir = _tmp13_;
#line 113 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp14_ = midori_paths_exec_path;
#line 113 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp15_ = g_build_path (G_DIR_SEPARATOR_S, _tmp14_, "profile", "tmp", NULL);
#line 113 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (midori_paths_tmp_dir);
#line 113 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		midori_paths_tmp_dir = _tmp15_;
#line 446 "midori-paths.c"
	} else {
		MidoriRuntimeMode _tmp16_;
#line 116 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp16_ = midori_paths_mode;
#line 116 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		if (_tmp16_ == MIDORI_RUNTIME_MODE_APP) {
#line 453 "midori-paths.c"
			const gchar* _tmp17_;
			const gchar* _tmp18_;
			gchar* _tmp19_;
			gchar* _tmp20_;
			gchar* _tmp21_;
			const gchar* _tmp22_;
			gchar* _tmp23_;
			const gchar* _tmp24_;
			gchar* _tmp25_;
			const gchar* _tmp26_;
			gchar* _tmp27_;
			const gchar* _tmp28_;
			gchar* _tmp29_;
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp17_ = g_get_user_data_dir ();
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp18_ = config;
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp19_ = g_compute_checksum_for_string (G_CHECKSUM_MD5, _tmp18_, (gsize) -1);
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp20_ = _tmp19_;
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp21_ = g_build_path (G_DIR_SEPARATOR_S, _tmp17_, PACKAGE_NAME, "apps", _tmp20_, NULL);
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (midori_paths_config_dir);
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			midori_paths_config_dir = _tmp21_;
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (_tmp20_);
#line 120 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp22_ = g_get_user_cache_dir ();
#line 120 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp23_ = g_build_path (G_DIR_SEPARATOR_S, _tmp22_, PACKAGE_NAME, NULL);
#line 120 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (midori_paths_cache_dir);
#line 120 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			midori_paths_cache_dir = _tmp23_;
#line 122 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp24_ = g_get_user_data_dir ();
#line 122 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp25_ = g_strdup (_tmp24_);
#line 122 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (midori_paths_user_data_dir);
#line 122 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			midori_paths_user_data_dir = _tmp25_;
#line 123 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp26_ = g_get_user_data_dir ();
#line 123 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp27_ = g_strdup (_tmp26_);
#line 123 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (midori_paths_user_data_dir_for_reading);
#line 123 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			midori_paths_user_data_dir_for_reading = _tmp27_;
#line 124 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp28_ = midori_paths_get_runtime_dir ();
#line 124 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp29_ = g_strdup (_tmp28_);
#line 124 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (midori_paths_tmp_dir);
#line 124 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			midori_paths_tmp_dir = _tmp29_;
#line 515 "midori-paths.c"
		} else {
			MidoriRuntimeMode _tmp30_;
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp30_ = midori_paths_mode;
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			if (_tmp30_ == MIDORI_RUNTIME_MODE_PRIVATE) {
#line 522 "midori-paths.c"
				gchar* _tmp31_ = NULL;
				gboolean _tmp32_ = FALSE;
				const gchar* _tmp33_;
				gchar* real_config = NULL;
				gchar* _tmp42_;
				gchar* _tmp43_ = NULL;
				const gchar* _tmp44_;
				gchar* _tmp45_;
				gchar* _tmp48_;
				const gchar* _tmp49_;
				gchar* _tmp50_;
				const gchar* _tmp51_;
				gchar* _tmp52_;
				const gchar* _tmp53_;
				gchar* _tmp54_;
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp33_ = config;
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp33_ != NULL) {
#line 542 "midori-paths.c"
					const gchar* _tmp34_;
					gboolean _tmp35_;
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp34_ = config;
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp35_ = g_path_is_absolute (_tmp34_);
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp32_ = !_tmp35_;
#line 551 "midori-paths.c"
				} else {
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp32_ = FALSE;
#line 555 "midori-paths.c"
				}
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp32_) {
#line 559 "midori-paths.c"
					gchar* _tmp36_;
					gchar* _tmp37_;
					const gchar* _tmp38_;
					gchar* _tmp39_;
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp36_ = g_get_current_dir ();
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp37_ = _tmp36_;
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp38_ = config;
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp39_ = g_build_filename (_tmp37_, _tmp38_, NULL);
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (_tmp31_);
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp31_ = _tmp39_;
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (_tmp37_);
#line 578 "midori-paths.c"
				} else {
					const gchar* _tmp40_;
					gchar* _tmp41_;
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp40_ = config;
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp41_ = g_strdup (_tmp40_);
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (_tmp31_);
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp31_ = _tmp41_;
#line 590 "midori-paths.c"
				}
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp42_ = g_strdup (_tmp31_);
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				real_config = _tmp42_;
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp44_ = real_config;
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp45_ = g_strdup (_tmp44_);
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp43_ = _tmp45_;
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp43_ == NULL) {
#line 604 "midori-paths.c"
					const gchar* _tmp46_;
					gchar* _tmp47_;
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp46_ = g_get_user_config_dir ();
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp47_ = g_build_path (G_DIR_SEPARATOR_S, _tmp46_, PACKAGE_NAME, NULL);
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (_tmp43_);
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp43_ = _tmp47_;
#line 615 "midori-paths.c"
				}
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp48_ = _tmp43_;
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp43_ = NULL;
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (midori_paths_readonly_dir);
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				midori_paths_readonly_dir = _tmp48_;
#line 131 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp49_ = g_get_user_cache_dir ();
#line 131 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp50_ = g_build_path (G_DIR_SEPARATOR_S, _tmp49_, PACKAGE_NAME, NULL);
#line 131 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (midori_paths_cache_dir_for_reading);
#line 131 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				midori_paths_cache_dir_for_reading = _tmp50_;
#line 133 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp51_ = g_get_user_data_dir ();
#line 133 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp52_ = g_strdup (_tmp51_);
#line 133 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (midori_paths_user_data_dir_for_reading);
#line 133 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				midori_paths_user_data_dir_for_reading = _tmp52_;
#line 134 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp53_ = midori_paths_get_runtime_dir ();
#line 134 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp54_ = g_strdup (_tmp53_);
#line 134 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (midori_paths_tmp_dir);
#line 134 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				midori_paths_tmp_dir = _tmp54_;
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (_tmp43_);
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (real_config);
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (_tmp31_);
#line 655 "midori-paths.c"
			} else {
				gchar* _tmp55_ = NULL;
				gboolean _tmp56_ = FALSE;
				const gchar* _tmp57_;
				gchar* real_config = NULL;
				gchar* _tmp66_;
				gchar* _tmp67_ = NULL;
				const gchar* _tmp68_;
				gchar* _tmp69_;
				gchar* _tmp72_;
				const gchar* _tmp73_;
				gchar* _tmp74_;
				const gchar* _tmp75_;
				gchar* _tmp76_;
				const gchar* _tmp77_;
				gchar* _tmp78_;
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp57_ = config;
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp57_ != NULL) {
#line 676 "midori-paths.c"
					const gchar* _tmp58_;
					gboolean _tmp59_;
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp58_ = config;
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp59_ = g_path_is_absolute (_tmp58_);
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp56_ = !_tmp59_;
#line 685 "midori-paths.c"
				} else {
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp56_ = FALSE;
#line 689 "midori-paths.c"
				}
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp56_) {
#line 693 "midori-paths.c"
					gchar* _tmp60_;
					gchar* _tmp61_;
					const gchar* _tmp62_;
					gchar* _tmp63_;
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp60_ = g_get_current_dir ();
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp61_ = _tmp60_;
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp62_ = config;
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp63_ = g_build_filename (_tmp61_, _tmp62_, NULL);
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (_tmp55_);
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp55_ = _tmp63_;
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (_tmp61_);
#line 712 "midori-paths.c"
				} else {
					const gchar* _tmp64_;
					gchar* _tmp65_;
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp64_ = config;
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp65_ = g_strdup (_tmp64_);
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (_tmp55_);
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp55_ = _tmp65_;
#line 724 "midori-paths.c"
				}
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp66_ = g_strdup (_tmp55_);
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				real_config = _tmp66_;
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp68_ = real_config;
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp69_ = g_strdup (_tmp68_);
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp67_ = _tmp69_;
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp67_ == NULL) {
#line 738 "midori-paths.c"
					const gchar* _tmp70_;
					gchar* _tmp71_;
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp70_ = g_get_user_config_dir ();
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp71_ = g_build_path (G_DIR_SEPARATOR_S, _tmp70_, PACKAGE_NAME, NULL);
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (_tmp67_);
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp67_ = _tmp71_;
#line 749 "midori-paths.c"
				}
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp72_ = _tmp67_;
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp67_ = NULL;
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (midori_paths_config_dir);
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				midori_paths_config_dir = _tmp72_;
#line 146 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp73_ = g_get_user_cache_dir ();
#line 146 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp74_ = g_build_path (G_DIR_SEPARATOR_S, _tmp73_, PACKAGE_NAME, NULL);
#line 146 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (midori_paths_cache_dir);
#line 146 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				midori_paths_cache_dir = _tmp74_;
#line 148 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp75_ = g_get_user_data_dir ();
#line 148 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp76_ = g_strdup (_tmp75_);
#line 148 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (midori_paths_user_data_dir);
#line 148 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				midori_paths_user_data_dir = _tmp76_;
#line 149 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp77_ = midori_paths_get_runtime_dir ();
#line 149 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp78_ = g_strdup (_tmp77_);
#line 149 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (midori_paths_tmp_dir);
#line 149 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				midori_paths_tmp_dir = _tmp78_;
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (_tmp67_);
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (real_config);
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (_tmp55_);
#line 789 "midori-paths.c"
			}
		}
	}
#line 166 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp79_ = midori_paths_user_data_dir;
#line 166 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp79_ != NULL) {
#line 797 "midori-paths.c"
		gchar* folder = NULL;
		const gchar* _tmp80_;
		gchar* _tmp81_;
		WebKitFaviconDatabase* _tmp82_;
		const gchar* _tmp83_;
#line 167 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp80_ = midori_paths_user_data_dir;
#line 167 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp81_ = g_build_filename (_tmp80_, "webkit", "icondatabase", NULL);
#line 167 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		folder = _tmp81_;
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp82_ = webkit_get_favicon_database ();
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp83_ = folder;
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		webkit_favicon_database_set_path (_tmp82_, _tmp83_);
#line 166 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (folder);
#line 817 "midori-paths.c"
	} else {
		WebKitFaviconDatabase* _tmp84_;
#line 183 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp84_ = webkit_get_favicon_database ();
#line 183 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		webkit_favicon_database_set_path (_tmp84_, NULL);
#line 824 "midori-paths.c"
	}
#line 188 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp85_ = gtk_icon_theme_get_default ();
#line 188 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp86_ = midori_paths_exec_path;
#line 188 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	gtk_icon_theme_append_search_path (_tmp85_, _tmp86_);
#line 191 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp87_ = g_strcmp0;
#line 191 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp88_ = g_getenv ("MIDORI_DEBUG");
#line 191 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp89_ = _tmp87_ (_tmp88_, "paths");
#line 191 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp89_ == 0) {
#line 840 "midori-paths.c"
		FILE* _tmp90_;
		const gchar* _tmp91_;
		const gchar* _tmp92_;
		const gchar* _tmp93_;
		const gchar* _tmp94_;
#line 192 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp90_ = stdout;
#line 192 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp91_ = midori_paths_config_dir;
#line 192 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp92_ = midori_paths_cache_dir;
#line 192 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp93_ = midori_paths_user_data_dir;
#line 192 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp94_ = midori_paths_tmp_dir;
#line 192 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		fprintf (_tmp90_, "config: %s\ncache: %s\nuser_data: %s\ntmp: %s\n", _tmp91_, _tmp92_, _tmp93_, _tmp94_);
#line 858 "midori-paths.c"
	}
}


static gint string_index_of_char (const gchar* self, gunichar c, gint start_index) {
	gint result = 0;
	gchar* _result_ = NULL;
	gint _tmp0_;
	gunichar _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
#line 1039 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, 0);
#line 1040 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp0_ = start_index;
#line 1040 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp1_ = c;
#line 1040 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp2_ = g_utf8_strchr (((gchar*) self) + _tmp0_, (gssize) -1, _tmp1_);
#line 1040 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_result_ = _tmp2_;
#line 1042 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp3_ = _result_;
#line 1042 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp3_ != NULL) {
#line 884 "midori-paths.c"
		gchar* _tmp4_;
#line 1043 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp4_ = _result_;
#line 1043 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		result = (gint) (_tmp4_ - ((gchar*) self));
#line 1043 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		return result;
#line 892 "midori-paths.c"
	} else {
#line 1045 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		result = -1;
#line 1045 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		return result;
#line 898 "midori-paths.c"
	}
}


static glong string_strnlen (gchar* str, glong maxlen) {
	glong result = 0L;
	gchar* end = NULL;
	gchar* _tmp0_;
	glong _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
#line 1330 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp0_ = str;
#line 1330 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp1_ = maxlen;
#line 1330 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp2_ = memchr (_tmp0_, 0, (gsize) _tmp1_);
#line 1330 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	end = _tmp2_;
#line 1331 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp3_ = end;
#line 1331 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp3_ == NULL) {
#line 922 "midori-paths.c"
		glong _tmp4_;
#line 1332 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp4_ = maxlen;
#line 1332 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		result = _tmp4_;
#line 1332 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		return result;
#line 930 "midori-paths.c"
	} else {
		gchar* _tmp5_;
		gchar* _tmp6_;
#line 1334 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp5_ = end;
#line 1334 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp6_ = str;
#line 1334 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		result = (glong) (_tmp5_ - _tmp6_);
#line 1334 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		return result;
#line 942 "midori-paths.c"
	}
}


static gchar* string_substring (const gchar* self, glong offset, glong len) {
	gchar* result = NULL;
	glong string_length = 0L;
	gboolean _tmp0_ = FALSE;
	glong _tmp1_;
	glong _tmp8_;
	glong _tmp14_;
	glong _tmp17_;
	glong _tmp18_;
	glong _tmp19_;
	glong _tmp20_;
	glong _tmp21_;
	gchar* _tmp22_;
#line 1341 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, NULL);
#line 1343 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp1_ = offset;
#line 1343 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp1_ >= ((glong) 0)) {
#line 966 "midori-paths.c"
		glong _tmp2_;
#line 1343 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp2_ = len;
#line 1343 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp0_ = _tmp2_ >= ((glong) 0);
#line 972 "midori-paths.c"
	} else {
#line 1343 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp0_ = FALSE;
#line 976 "midori-paths.c"
	}
#line 1343 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp0_) {
#line 980 "midori-paths.c"
		glong _tmp3_;
		glong _tmp4_;
		glong _tmp5_;
#line 1345 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp3_ = offset;
#line 1345 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp4_ = len;
#line 1345 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp5_ = string_strnlen ((gchar*) self, _tmp3_ + _tmp4_);
#line 1345 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		string_length = _tmp5_;
#line 992 "midori-paths.c"
	} else {
		gint _tmp6_;
		gint _tmp7_;
#line 1347 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp6_ = strlen (self);
#line 1347 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp7_ = _tmp6_;
#line 1347 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		string_length = (glong) _tmp7_;
#line 1002 "midori-paths.c"
	}
#line 1350 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp8_ = offset;
#line 1350 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp8_ < ((glong) 0)) {
#line 1008 "midori-paths.c"
		glong _tmp9_;
		glong _tmp10_;
		glong _tmp11_;
#line 1351 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp9_ = string_length;
#line 1351 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp10_ = offset;
#line 1351 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		offset = _tmp9_ + _tmp10_;
#line 1352 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp11_ = offset;
#line 1352 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		g_return_val_if_fail (_tmp11_ >= ((glong) 0), NULL);
#line 1022 "midori-paths.c"
	} else {
		glong _tmp12_;
		glong _tmp13_;
#line 1354 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp12_ = offset;
#line 1354 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp13_ = string_length;
#line 1354 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		g_return_val_if_fail (_tmp12_ <= _tmp13_, NULL);
#line 1032 "midori-paths.c"
	}
#line 1356 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp14_ = len;
#line 1356 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp14_ < ((glong) 0)) {
#line 1038 "midori-paths.c"
		glong _tmp15_;
		glong _tmp16_;
#line 1357 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp15_ = string_length;
#line 1357 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp16_ = offset;
#line 1357 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		len = _tmp15_ - _tmp16_;
#line 1047 "midori-paths.c"
	}
#line 1359 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp17_ = offset;
#line 1359 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp18_ = len;
#line 1359 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp19_ = string_length;
#line 1359 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	g_return_val_if_fail ((_tmp17_ + _tmp18_) <= _tmp19_, NULL);
#line 1360 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp20_ = offset;
#line 1360 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp21_ = len;
#line 1360 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp22_ = g_strndup (((gchar*) self) + _tmp20_, (gsize) _tmp21_);
#line 1360 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	result = _tmp22_;
#line 1360 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	return result;
#line 1067 "midori-paths.c"
}


void midori_paths_mkdir_with_parents (const gchar* path, gint mode) {
	const gchar* _tmp0_;
	gint _tmp1_;
	gint i = 0;
	const gchar* _tmp2_;
	gint _tmp3_;
#line 197 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_if_fail (path != NULL);
#line 199 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = path;
#line 199 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = access (_tmp0_, F_OK);
#line 199 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp1_ == 0) {
#line 200 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return;
#line 1087 "midori-paths.c"
	}
#line 201 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = path;
#line 201 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = string_index_of_char (_tmp2_, (gunichar) G_DIR_SEPARATOR, 0);
#line 201 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	i = _tmp3_;
#line 1095 "midori-paths.c"
	{
		gboolean _tmp4_ = FALSE;
#line 202 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = TRUE;
#line 202 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		while (TRUE) {
#line 1102 "midori-paths.c"
			gchar* fn = NULL;
			const gchar* _tmp6_;
			gint _tmp7_;
			gchar* _tmp8_;
			const gchar* _tmp9_;
			gint _tmp10_;
			const gchar* _tmp18_;
			gint _tmp19_;
			gint _tmp20_;
#line 202 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			if (!_tmp4_) {
#line 1114 "midori-paths.c"
				gint _tmp5_;
#line 216 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp5_ = i;
#line 216 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (!(_tmp5_ != -1)) {
#line 216 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					break;
#line 1122 "midori-paths.c"
				}
			}
#line 202 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp4_ = FALSE;
#line 203 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp6_ = path;
#line 203 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp7_ = i;
#line 203 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp8_ = string_substring (_tmp6_, (glong) _tmp7_, (glong) -1);
#line 203 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			fn = _tmp8_;
#line 204 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp9_ = fn;
#line 204 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp10_ = access (_tmp9_, F_OK);
#line 204 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			if (_tmp10_ != 0) {
#line 1141 "midori-paths.c"
				const gchar* _tmp11_;
				gint _tmp12_;
				gint _tmp13_;
#line 205 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp11_ = fn;
#line 205 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp12_ = mode;
#line 205 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp13_ = g_mkdir (_tmp11_, _tmp12_);
#line 205 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp13_ == -1) {
#line 1153 "midori-paths.c"
					const gchar* _tmp14_;
					gint _tmp15_;
#line 207 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp14_ = path;
#line 207 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp15_ = mode;
#line 207 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					g_mkdir_with_parents (_tmp14_, _tmp15_);
#line 208 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (fn);
#line 208 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					return;
#line 1166 "midori-paths.c"
				}
			} else {
				const gchar* _tmp16_;
				gboolean _tmp17_;
#line 211 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp16_ = fn;
#line 211 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp17_ = g_file_test (_tmp16_, G_FILE_TEST_IS_SYMLINK);
#line 211 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (!_tmp17_) {
#line 212 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (fn);
#line 212 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					return;
#line 1181 "midori-paths.c"
				}
			}
#line 214 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp18_ = path;
#line 214 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp19_ = i;
#line 214 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp20_ = string_index_of_char (_tmp18_, (gunichar) G_DIR_SEPARATOR, _tmp19_);
#line 214 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			i = _tmp20_;
#line 202 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (fn);
#line 1194 "midori-paths.c"
		}
	}
}


void midori_paths_remove_path (const gchar* path) {
	GError * _inner_error_ = NULL;
#line 219 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_if_fail (path != NULL);
#line 1204 "midori-paths.c"
	{
		GDir* dir = NULL;
		const gchar* _tmp0_;
		GDir* _tmp1_;
		gchar* name = NULL;
#line 221 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp0_ = path;
#line 221 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp1_ = g_dir_open (_tmp0_, (guint) 0, &_inner_error_);
#line 221 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		dir = _tmp1_;
#line 221 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 1218 "midori-paths.c"
			goto __catch2_g_error;
		}
#line 223 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		while (TRUE) {
#line 1223 "midori-paths.c"
			GDir* _tmp2_;
			const gchar* _tmp3_;
			gchar* _tmp4_;
			const gchar* _tmp5_;
			const gchar* _tmp6_;
			const gchar* _tmp7_;
			gchar* _tmp8_;
			gchar* _tmp9_;
#line 224 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp2_ = dir;
#line 224 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp3_ = g_dir_read_name (_tmp2_);
#line 224 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp4_ = g_strdup (_tmp3_);
#line 224 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (name);
#line 224 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			name = _tmp4_;
#line 225 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp5_ = name;
#line 225 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			if (_tmp5_ == NULL) {
#line 226 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				break;
#line 1248 "midori-paths.c"
			}
#line 227 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp6_ = path;
#line 227 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp7_ = name;
#line 227 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp8_ = g_build_filename (_tmp6_, _tmp7_, NULL);
#line 227 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp9_ = _tmp8_;
#line 227 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			midori_paths_remove_path (_tmp9_);
#line 227 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (_tmp9_);
#line 1262 "midori-paths.c"
		}
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (name);
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_dir_close0 (dir);
#line 1268 "midori-paths.c"
	}
	goto __finally2;
	__catch2_g_error:
	{
		GError* _error_ = NULL;
		const gchar* _tmp10_;
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_error_ = _inner_error_;
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_inner_error_ = NULL;
#line 231 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp10_ = path;
#line 231 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		g_remove (_tmp10_);
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_error_free0 (_error_);
#line 1285 "midori-paths.c"
	}
	__finally2:
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.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 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		g_clear_error (&_inner_error_);
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return;
#line 1296 "midori-paths.c"
	}
}


const gchar* midori_paths_get_config_dir_for_writing (void) {
	const gchar* result = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
#line 236 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_config_dir;
#line 236 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "config_dir != null");
#line 237 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_config_dir;
#line 237 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_mkdir_with_parents (_tmp1_, 0700);
#line 238 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = midori_paths_config_dir;
#line 238 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp2_;
#line 238 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1320 "midori-paths.c"
}


static gboolean string_contains (const gchar* self, const gchar* needle) {
	gboolean result = FALSE;
	const gchar* _tmp0_;
	gchar* _tmp1_;
#line 1411 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, FALSE);
#line 1411 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	g_return_val_if_fail (needle != NULL, FALSE);
#line 1412 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp0_ = needle;
#line 1412 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp1_ = strstr ((gchar*) self, (gchar*) _tmp0_);
#line 1412 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	result = _tmp1_ != NULL;
#line 1412 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	return result;
#line 1340 "midori-paths.c"
}


gchar* midori_paths_get_extension_config_dir (const gchar* extension) {
	gchar* result = NULL;
	const gchar* _tmp0_;
	gchar* folder = NULL;
	const gchar* _tmp1_;
	gboolean _tmp2_;
	const gchar* _tmp15_;
#line 241 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (extension != NULL, NULL);
#line 242 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_config_dir;
#line 242 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "config_dir != null");
#line 244 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = extension;
#line 244 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = string_contains (_tmp1_, ".");
#line 244 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp2_) {
#line 1363 "midori-paths.c"
		const gchar* _tmp3_;
		const gchar* _tmp4_;
		gchar* _tmp5_;
#line 245 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = midori_paths_config_dir;
#line 245 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = extension;
#line 245 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp5_ = g_build_filename (_tmp3_, "extensions", _tmp4_, NULL);
#line 245 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (folder);
#line 245 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		folder = _tmp5_;
#line 1377 "midori-paths.c"
	} else {
		const gchar* _tmp6_;
		const gchar* _tmp7_;
		gchar* _tmp8_;
		gchar* _tmp9_;
		gchar* _tmp10_;
		gchar* _tmp11_;
		gchar* _tmp12_;
		gchar* _tmp13_;
		gchar* _tmp14_;
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp6_ = midori_paths_config_dir;
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp7_ = extension;
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp8_ = g_strconcat (MODULE_PREFIX, _tmp7_, NULL);
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp9_ = _tmp8_;
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp10_ = g_strconcat (_tmp9_, ".", NULL);
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp11_ = _tmp10_;
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp12_ = g_strconcat (_tmp11_, G_MODULE_SUFFIX, NULL);
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp13_ = _tmp12_;
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp14_ = g_build_filename (_tmp6_, "extensions", _tmp13_, NULL);
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (folder);
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		folder = _tmp14_;
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp13_);
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp11_);
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp9_);
#line 1416 "midori-paths.c"
	}
#line 249 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp15_ = folder;
#line 249 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_mkdir_with_parents (_tmp15_, 0700);
#line 250 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = folder;
#line 250 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1426 "midori-paths.c"
}


gchar* midori_paths_get_extension_preset_filename (const gchar* extension, const gchar* filename) {
	gchar* result = NULL;
	const gchar* _tmp0_;
	gchar* preset_filename = NULL;
	const gchar* _tmp1_;
	gchar* _tmp2_;
	const gchar* _tmp3_;
	gboolean _tmp4_;
	const gchar* _tmp11_;
	gboolean _tmp12_;
	const gchar* _tmp19_;
	gchar* _tmp20_;
	gchar* _tmp21_;
	const gchar* _tmp22_;
	gchar* _tmp23_;
	gchar* _tmp24_;
#line 253 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (extension != NULL, NULL);
#line 253 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (filename != NULL, NULL);
#line 254 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_exec_path;
#line 254 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "exec_path != null");
#line 255 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = extension;
#line 255 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = g_strdup (_tmp1_);
#line 255 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	preset_filename = _tmp2_;
#line 256 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = extension;
#line 256 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp4_ = g_str_has_prefix (_tmp3_, MODULE_PREFIX);
#line 256 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp4_) {
#line 1466 "midori-paths.c"
		const gchar* _tmp5_;
		gchar** _tmp6_;
		gchar** _tmp7_;
		gchar** _tmp8_;
		gint _tmp8__length1;
		const gchar* _tmp9_;
		gchar* _tmp10_;
#line 257 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp5_ = extension;
#line 257 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp7_ = _tmp6_ = g_strsplit (_tmp5_, MODULE_PREFIX, 0);
#line 257 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp8_ = _tmp7_;
#line 257 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp8__length1 = _vala_array_length (_tmp6_);
#line 257 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp9_ = _tmp8_[1];
#line 257 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp10_ = g_strdup (_tmp9_);
#line 257 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (preset_filename);
#line 257 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		preset_filename = _tmp10_;
#line 257 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp8_ = (_vala_array_free (_tmp8_, _tmp8__length1, (GDestroyNotify) g_free), NULL);
#line 1492 "midori-paths.c"
	}
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp11_ = extension;
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp12_ = g_str_has_suffix (_tmp11_, MODULE_SUFFIX);
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp12_) {
#line 1500 "midori-paths.c"
		const gchar* _tmp13_;
		gchar** _tmp14_;
		gchar** _tmp15_;
		gchar** _tmp16_;
		gint _tmp16__length1;
		const gchar* _tmp17_;
		gchar* _tmp18_;
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp13_ = preset_filename;
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp15_ = _tmp14_ = g_strsplit (_tmp13_, MODULE_SUFFIX, 0);
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp16_ = _tmp15_;
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp16__length1 = _vala_array_length (_tmp14_);
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp17_ = _tmp16_[0];
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp18_ = g_strdup (_tmp17_);
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (preset_filename);
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		preset_filename = _tmp18_;
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp16_ = (_vala_array_free (_tmp16_, _tmp16__length1, (GDestroyNotify) g_free), NULL);
#line 1526 "midori-paths.c"
	}
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp19_ = preset_filename;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp20_ = g_build_filename ("extensions", _tmp19_, NULL);
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp21_ = _tmp20_;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp22_ = filename;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp23_ = midori_paths_get_preset_filename (_tmp21_, _tmp22_);
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp24_ = _tmp23_;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (_tmp21_);
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp24_;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (preset_filename);
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1548 "midori-paths.c"
}


gchar* midori_paths_get_config_filename_for_writing (const gchar* filename) {
	gchar* result = NULL;
	MidoriRuntimeMode _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	const gchar* _tmp4_;
	gchar* _tmp5_;
#line 266 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (filename != NULL, NULL);
#line 267 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_mode;
#line 267 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != MIDORI_RUNTIME_MODE_UNDEFINED, "mode != RuntimeMode.UNDEFINED");
#line 268 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_config_dir;
#line 268 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp1_ != NULL, "config_dir != null");
#line 269 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = midori_paths_config_dir;
#line 269 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_mkdir_with_parents (_tmp2_, 0700);
#line 270 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = midori_paths_config_dir;
#line 270 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp4_ = filename;
#line 270 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp5_ = g_build_path (G_DIR_SEPARATOR_S, _tmp3_, _tmp4_, NULL);
#line 270 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp5_;
#line 270 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1584 "midori-paths.c"
}


const gchar* midori_paths_get_cache_dir (void) {
	const gchar* result = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
#line 274 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_cache_dir;
#line 274 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "cache_dir != null");
#line 275 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_cache_dir;
#line 275 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp1_;
#line 275 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1602 "midori-paths.c"
}


const gchar* midori_paths_get_user_data_dir (void) {
	const gchar* result = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
#line 279 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_user_data_dir;
#line 279 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "user_data_dir != null");
#line 280 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_user_data_dir;
#line 280 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp1_;
#line 280 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1620 "midori-paths.c"
}


const gchar* midori_paths_get_user_data_dir_for_reading (void) {
	const gchar* result = NULL;
	gboolean _tmp0_ = FALSE;
	const gchar* _tmp1_;
	const gchar* _tmp3_;
	const gchar* _tmp5_;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_user_data_dir_for_reading;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp1_ != NULL) {
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp0_ = TRUE;
#line 1636 "midori-paths.c"
	} else {
		const gchar* _tmp2_;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp2_ = midori_paths_user_data_dir;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp0_ = _tmp2_ != NULL;
#line 1643 "midori-paths.c"
	}
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_, "user_data_dir_for_reading != null || user_data_dir != null");
#line 285 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = midori_paths_user_data_dir;
#line 285 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp3_ != NULL) {
#line 1651 "midori-paths.c"
		const gchar* _tmp4_;
#line 286 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = midori_paths_user_data_dir;
#line 286 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = _tmp4_;
#line 286 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 1659 "midori-paths.c"
	}
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp5_ = midori_paths_user_data_dir_for_reading;
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp5_;
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1667 "midori-paths.c"
}


const gchar* midori_paths_get_cache_dir_for_reading (void) {
	const gchar* result = NULL;
	gboolean _tmp0_ = FALSE;
	const gchar* _tmp1_;
	const gchar* _tmp3_;
	const gchar* _tmp5_;
#line 291 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_cache_dir_for_reading;
#line 291 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp1_ != NULL) {
#line 291 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp0_ = TRUE;
#line 1683 "midori-paths.c"
	} else {
		const gchar* _tmp2_;
#line 291 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp2_ = midori_paths_cache_dir;
#line 291 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp0_ = _tmp2_ != NULL;
#line 1690 "midori-paths.c"
	}
#line 291 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_, "cache_dir_for_reading != null || cache_dir != null");
#line 292 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = midori_paths_cache_dir;
#line 292 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp3_ != NULL) {
#line 1698 "midori-paths.c"
		const gchar* _tmp4_;
#line 293 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = midori_paths_cache_dir;
#line 293 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = _tmp4_;
#line 293 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 1706 "midori-paths.c"
	}
#line 294 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp5_ = midori_paths_cache_dir_for_reading;
#line 294 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp5_;
#line 294 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1714 "midori-paths.c"
}


const gchar* midori_paths_get_tmp_dir (void) {
	const gchar* result = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
#line 298 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_tmp_dir;
#line 298 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "tmp_dir != null");
#line 299 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_tmp_dir;
#line 299 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp1_;
#line 299 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1732 "midori-paths.c"
}


gchar* midori_paths_make_tmp_dir (const gchar* tmpl) {
	gchar* result = NULL;
	const gchar* _tmp0_;
	GError * _inner_error_ = NULL;
#line 302 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (tmpl != NULL, NULL);
#line 303 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_tmp_dir;
#line 303 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "tmp_dir != null");
#line 1746 "midori-paths.c"
	{
		const gchar* _tmp1_;
		gchar* _tmp2_ = NULL;
		const gchar* _tmp3_;
		gchar* _tmp4_;
		gchar* _tmp5_;
#line 305 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp1_ = g_get_tmp_dir ();
#line 305 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		midori_paths_mkdir_with_parents (_tmp1_, 0700);
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = tmpl;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = g_dir_make_tmp (_tmp3_, &_inner_error_);
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp2_ = _tmp4_;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 1765 "midori-paths.c"
			goto __catch3_g_error;
		}
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp5_ = _tmp2_;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp2_ = NULL;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = _tmp5_;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp2_);
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 1778 "midori-paths.c"
	}
	goto __finally3;
	__catch3_g_error:
	{
		GError* _error_ = NULL;
		const gchar* _tmp6_;
#line 304 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_error_ = _inner_error_;
#line 304 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_inner_error_ = NULL;
#line 309 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp6_ = _error_->message;
#line 309 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		g_error ("midori-paths.vala:309: %s", _tmp6_);
#line 304 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_error_free0 (_error_);
#line 1795 "midori-paths.c"
	}
	__finally3:
#line 304 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.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 304 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_clear_error (&_inner_error_);
#line 304 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return NULL;
#line 1804 "midori-paths.c"
}


static gchar** _vala_array_dup1 (gchar** self, int length) {
	gchar** result;
	int i;
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = g_new0 (gchar*, length + 1);
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	for (i = 0; i < length; i++) {
#line 1815 "midori-paths.c"
		gchar* _tmp0_;
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp0_ = g_strdup (self[i]);
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result[i] = _tmp0_;
#line 1821 "midori-paths.c"
	}
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 1825 "midori-paths.c"
}


void midori_paths_init_exec_path (gchar** new_command_line, int new_command_line_length1) {
	gchar** _tmp0_;
	gint _tmp0__length1;
	gchar** _tmp1_;
	gint _tmp1__length1;
	gchar** _tmp2_;
	gint _tmp2__length1;
	gchar* executable = NULL;
	const gchar* _tmp25_;
	GFile* _tmp26_;
	GFile* _tmp27_;
	GFile* _tmp28_;
	GFile* _tmp29_;
	GFile* _tmp30_;
	GFile* _tmp31_;
	gchar* _tmp32_;
	GCompareFunc _tmp33_;
	const gchar* _tmp34_;
	gint _tmp35_;
	GError * _inner_error_ = NULL;
#line 314 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_command_line;
#line 314 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0__length1 = midori_paths_command_line_length1;
#line 314 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ == NULL, "command_line == null");
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = new_command_line;
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1__length1 = new_command_line_length1;
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = (_tmp1_ != NULL) ? _vala_array_dup1 (_tmp1_, _tmp1__length1) : ((gpointer) _tmp1_);
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2__length1 = _tmp1__length1;
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_command_line = (_vala_array_free (midori_paths_command_line, midori_paths_command_line_length1, (GDestroyNotify) g_free), NULL);
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_command_line = _tmp2_;
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_command_line_length1 = _tmp2__length1;
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_midori_paths_command_line_size_ = midori_paths_command_line_length1;
#line 1871 "midori-paths.c"
	{
		gchar** _tmp3_;
		gint _tmp3__length1;
		const gchar* _tmp4_;
		gboolean _tmp5_;
#line 322 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = midori_paths_command_line;
#line 322 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3__length1 = midori_paths_command_line_length1;
#line 322 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = _tmp3_[0];
#line 322 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp5_ = g_path_is_absolute (_tmp4_);
#line 322 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		if (!_tmp5_) {
#line 1887 "midori-paths.c"
			gchar* program = NULL;
			gchar** _tmp6_;
			gint _tmp6__length1;
			const gchar* _tmp7_;
			gchar* _tmp8_;
			const gchar* _tmp9_;
			gboolean _tmp10_;
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp6_ = midori_paths_command_line;
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp6__length1 = midori_paths_command_line_length1;
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp7_ = _tmp6_[0];
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp8_ = g_find_program_in_path (_tmp7_);
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			program = _tmp8_;
#line 324 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp9_ = program;
#line 324 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp10_ = g_file_test (_tmp9_, G_FILE_TEST_IS_SYMLINK);
#line 324 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			if (_tmp10_) {
#line 1911 "midori-paths.c"
				gchar* _tmp11_ = NULL;
				const gchar* _tmp12_;
				gchar* _tmp13_;
				gchar* _tmp14_;
#line 325 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp12_ = program;
#line 325 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp13_ = g_file_read_link (_tmp12_, &_inner_error_);
#line 325 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp11_ = _tmp13_;
#line 325 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 325 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (program);
#line 1926 "midori-paths.c"
					goto __catch4_g_error;
				}
#line 325 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp14_ = _tmp11_;
#line 325 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp11_ = NULL;
#line 325 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (executable);
#line 325 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				executable = _tmp14_;
#line 324 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (_tmp11_);
#line 1939 "midori-paths.c"
			} else {
				const gchar* _tmp15_;
				gchar* _tmp16_;
#line 327 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp15_ = program;
#line 327 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp16_ = g_strdup (_tmp15_);
#line 327 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (executable);
#line 327 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				executable = _tmp16_;
#line 1951 "midori-paths.c"
			}
#line 322 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (program);
#line 1955 "midori-paths.c"
		} else {
			gchar* _tmp17_ = NULL;
			gchar** _tmp18_;
			gint _tmp18__length1;
			const gchar* _tmp19_;
			gchar* _tmp20_;
			gchar* _tmp21_;
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp18_ = midori_paths_command_line;
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp18__length1 = midori_paths_command_line_length1;
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp19_ = _tmp18_[0];
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp20_ = g_file_read_link (_tmp19_, &_inner_error_);
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp17_ = _tmp20_;
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 1975 "midori-paths.c"
				goto __catch4_g_error;
			}
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp21_ = _tmp17_;
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp17_ = NULL;
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (executable);
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			executable = _tmp21_;
#line 322 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_free0 (_tmp17_);
#line 1988 "midori-paths.c"
		}
	}
	goto __finally4;
	__catch4_g_error:
	{
		GError* _error_ = NULL;
		gchar** _tmp22_;
		gint _tmp22__length1;
		const gchar* _tmp23_;
		gchar* _tmp24_;
#line 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_error_ = _inner_error_;
#line 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_inner_error_ = NULL;
#line 333 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp22_ = midori_paths_command_line;
#line 333 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp22__length1 = midori_paths_command_line_length1;
#line 333 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp23_ = _tmp22_[0];
#line 333 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp24_ = g_strdup (_tmp23_);
#line 333 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (executable);
#line 333 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		executable = _tmp24_;
#line 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_error_free0 (_error_);
#line 2017 "midori-paths.c"
	}
	__finally4:
#line 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (executable);
#line 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.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 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		g_clear_error (&_inner_error_);
#line 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return;
#line 2030 "midori-paths.c"
	}
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp25_ = executable;
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp26_ = g_file_new_for_path (_tmp25_);
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp27_ = _tmp26_;
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp28_ = g_file_get_parent (_tmp27_);
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp29_ = _tmp28_;
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp30_ = g_file_get_parent (_tmp29_);
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp31_ = _tmp30_;
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp32_ = g_file_get_path (_tmp31_);
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (midori_paths_exec_path);
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_exec_path = _tmp32_;
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_object_unref0 (_tmp31_);
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_object_unref0 (_tmp29_);
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_object_unref0 (_tmp27_);
#line 338 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp33_ = g_strcmp0;
#line 338 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp34_ = g_getenv ("MIDORI_DEBUG");
#line 338 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp35_ = _tmp33_ (_tmp34_, "paths");
#line 338 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp35_ == 0) {
#line 2066 "midori-paths.c"
		FILE* _tmp36_;
		gchar* _tmp37_;
		gchar* _tmp38_;
		const gchar* _tmp39_;
		gchar* _tmp40_;
		gchar* _tmp41_;
		gchar* _tmp42_;
		gchar* _tmp43_;
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp36_ = stdout;
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp37_ = midori_paths_get_command_line_str (TRUE);
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp38_ = _tmp37_;
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp39_ = midori_paths_exec_path;
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp40_ = midori_paths_get_res_filename ("about.css");
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp41_ = _tmp40_;
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp42_ = midori_paths_get_lib_path (PACKAGE_NAME);
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp43_ = _tmp42_;
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		fprintf (_tmp36_, "command_line: %s\nexec_path: %s\nres: %s\nlib: %s\n", _tmp38_, _tmp39_, _tmp41_, _tmp43_);
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp43_);
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp41_);
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp38_);
#line 2099 "midori-paths.c"
	}
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (executable);
#line 2103 "midori-paths.c"
}


gchar** midori_paths_get_command_line (int* result_length1) {
	gchar** result = NULL;
	gchar** _tmp0_;
	gint _tmp0__length1;
	gchar** _tmp1_;
	gint _tmp1__length1;
	gchar** _tmp2_;
	gint _tmp2__length1;
#line 346 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_command_line;
#line 346 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0__length1 = midori_paths_command_line_length1;
#line 346 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "command_line != null");
#line 347 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_command_line;
#line 347 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1__length1 = midori_paths_command_line_length1;
#line 347 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = _tmp1_;
#line 347 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2__length1 = _tmp1__length1;
#line 347 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (result_length1) {
#line 347 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		*result_length1 = _tmp2__length1;
#line 2133 "midori-paths.c"
	}
#line 347 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp2_;
#line 347 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 2139 "midori-paths.c"
}


static gchar* _vala_g_strjoinv (const gchar* separator, gchar** str_array, int str_array_length1) {
	gchar* result = NULL;
	const gchar* _tmp0_;
	gboolean _tmp1_ = FALSE;
	gchar** _tmp2_;
	gint _tmp2__length1;
#line 1086 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp0_ = separator;
#line 1086 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp0_ == NULL) {
#line 1087 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		separator = "";
#line 2155 "midori-paths.c"
	}
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp2_ = str_array;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	_tmp2__length1 = str_array_length1;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp2_ != NULL) {
#line 2163 "midori-paths.c"
		gboolean _tmp3_ = FALSE;
		gchar** _tmp4_;
		gint _tmp4__length1;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp4_ = str_array;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp4__length1 = str_array_length1;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		if (_tmp4__length1 > 0) {
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			_tmp3_ = TRUE;
#line 2175 "midori-paths.c"
		} else {
			gboolean _tmp5_ = FALSE;
			gchar** _tmp6_;
			gint _tmp6__length1;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			_tmp6_ = str_array;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			_tmp6__length1 = str_array_length1;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			if (_tmp6__length1 == -1) {
#line 2186 "midori-paths.c"
				gchar** _tmp7_;
				gint _tmp7__length1;
				const gchar* _tmp8_;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp7_ = str_array;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp7__length1 = str_array_length1;
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp8_ = _tmp7_[0];
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp5_ = _tmp8_ != NULL;
#line 2198 "midori-paths.c"
			} else {
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp5_ = FALSE;
#line 2202 "midori-paths.c"
			}
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			_tmp3_ = _tmp5_;
#line 2206 "midori-paths.c"
		}
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp1_ = _tmp3_;
#line 2210 "midori-paths.c"
	} else {
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp1_ = FALSE;
#line 2214 "midori-paths.c"
	}
#line 1089 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp1_) {
#line 2218 "midori-paths.c"
		gint i = 0;
		gsize len = 0UL;
		gint _tmp31_;
		gint _tmp33_;
		gint _tmp34_;
		gsize _tmp35_;
		const gchar* _tmp36_;
		gint _tmp37_;
		gint _tmp38_;
		gint _tmp39_;
		const gchar* res = NULL;
		gsize _tmp40_;
		void* _tmp41_;
		void* ptr = NULL;
		const gchar* _tmp42_;
		gchar** _tmp43_;
		gint _tmp43__length1;
		const gchar* _tmp44_;
		void* _tmp45_;
		const gchar* _tmp62_;
#line 1091 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		len = (gsize) 1;
#line 2241 "midori-paths.c"
		{
			gboolean _tmp9_ = FALSE;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			i = 0;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			_tmp9_ = TRUE;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			while (TRUE) {
#line 2250 "midori-paths.c"
				gboolean _tmp11_ = FALSE;
				gboolean _tmp12_ = FALSE;
				gchar** _tmp13_;
				gint _tmp13__length1;
				gint _tmp21_ = 0;
				gchar** _tmp22_;
				gint _tmp22__length1;
				gint _tmp23_;
				const gchar* _tmp24_;
				gsize _tmp30_;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				if (!_tmp9_) {
#line 2263 "midori-paths.c"
					gint _tmp10_;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp10_ = i;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					i = _tmp10_ + 1;
#line 2269 "midori-paths.c"
				}
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp9_ = FALSE;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp13_ = str_array;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp13__length1 = str_array_length1;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				if (_tmp13__length1 != -1) {
#line 2279 "midori-paths.c"
					gint _tmp14_;
					gchar** _tmp15_;
					gint _tmp15__length1;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp14_ = i;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp15_ = str_array;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp15__length1 = str_array_length1;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp12_ = _tmp14_ < _tmp15__length1;
#line 2291 "midori-paths.c"
				} else {
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp12_ = FALSE;
#line 2295 "midori-paths.c"
				}
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				if (_tmp12_) {
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp11_ = TRUE;
#line 2301 "midori-paths.c"
				} else {
					gboolean _tmp16_ = FALSE;
					gchar** _tmp17_;
					gint _tmp17__length1;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp17_ = str_array;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp17__length1 = str_array_length1;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					if (_tmp17__length1 == -1) {
#line 2312 "midori-paths.c"
						gchar** _tmp18_;
						gint _tmp18__length1;
						gint _tmp19_;
						const gchar* _tmp20_;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
						_tmp18_ = str_array;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
						_tmp18__length1 = str_array_length1;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
						_tmp19_ = i;
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
						_tmp20_ = _tmp18_[_tmp19_];
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
						_tmp16_ = _tmp20_ != NULL;
#line 2327 "midori-paths.c"
					} else {
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
						_tmp16_ = FALSE;
#line 2331 "midori-paths.c"
					}
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp11_ = _tmp16_;
#line 2335 "midori-paths.c"
				}
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				if (!_tmp11_) {
#line 1092 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					break;
#line 2341 "midori-paths.c"
				}
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp22_ = str_array;
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp22__length1 = str_array_length1;
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp23_ = i;
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp24_ = _tmp22_[_tmp23_];
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				if (_tmp24_ != NULL) {
#line 2353 "midori-paths.c"
					gchar** _tmp25_;
					gint _tmp25__length1;
					gint _tmp26_;
					const gchar* _tmp27_;
					gint _tmp28_;
					gint _tmp29_;
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp25_ = str_array;
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp25__length1 = str_array_length1;
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp26_ = i;
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp27_ = _tmp25_[_tmp26_];
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp28_ = strlen ((const gchar*) _tmp27_);
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp29_ = _tmp28_;
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp21_ = _tmp29_;
#line 2374 "midori-paths.c"
				} else {
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp21_ = 0;
#line 2378 "midori-paths.c"
				}
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp30_ = len;
#line 1093 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				len = _tmp30_ + _tmp21_;
#line 2384 "midori-paths.c"
			}
		}
#line 1095 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp31_ = i;
#line 1095 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		if (_tmp31_ == 0) {
#line 2391 "midori-paths.c"
			gchar* _tmp32_;
#line 1096 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			_tmp32_ = g_strdup ("");
#line 1096 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			result = _tmp32_;
#line 1096 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			return result;
#line 2399 "midori-paths.c"
		}
#line 1098 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp33_ = i;
#line 1098 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		str_array_length1 = _tmp33_;
#line 1098 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp34_ = str_array_length1;
#line 1099 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp35_ = len;
#line 1099 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp36_ = separator;
#line 1099 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp37_ = strlen ((const gchar*) _tmp36_);
#line 1099 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp38_ = _tmp37_;
#line 1099 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp39_ = i;
#line 1099 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		len = _tmp35_ + (_tmp38_ * (_tmp39_ - 1));
#line 1101 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp40_ = len;
#line 1101 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp41_ = g_malloc (_tmp40_);
#line 1101 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		res = _tmp41_;
#line 1102 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp42_ = res;
#line 1102 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp43_ = str_array;
#line 1102 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp43__length1 = str_array_length1;
#line 1102 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp44_ = _tmp43_[0];
#line 1102 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp45_ = g_stpcpy ((void*) _tmp42_, (const gchar*) _tmp44_);
#line 1102 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		ptr = _tmp45_;
#line 2437 "midori-paths.c"
		{
			gboolean _tmp46_ = FALSE;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			i = 1;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			_tmp46_ = TRUE;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			while (TRUE) {
#line 2446 "midori-paths.c"
				gint _tmp48_;
				gchar** _tmp49_;
				gint _tmp49__length1;
				void* _tmp50_;
				const gchar* _tmp51_;
				void* _tmp52_;
				const gchar* _tmp53_ = NULL;
				gchar** _tmp54_;
				gint _tmp54__length1;
				gint _tmp55_;
				const gchar* _tmp56_;
				void* _tmp60_;
				void* _tmp61_;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				if (!_tmp46_) {
#line 2462 "midori-paths.c"
					gint _tmp47_;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp47_ = i;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					i = _tmp47_ + 1;
#line 2468 "midori-paths.c"
				}
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp46_ = FALSE;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp48_ = i;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp49_ = str_array;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp49__length1 = str_array_length1;
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				if (!(_tmp48_ < _tmp49__length1)) {
#line 1103 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					break;
#line 2482 "midori-paths.c"
				}
#line 1104 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp50_ = ptr;
#line 1104 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp51_ = separator;
#line 1104 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp52_ = g_stpcpy (_tmp50_, (const gchar*) _tmp51_);
#line 1104 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				ptr = _tmp52_;
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp54_ = str_array;
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp54__length1 = str_array_length1;
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp55_ = i;
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp56_ = _tmp54_[_tmp55_];
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				if (_tmp56_ != NULL) {
#line 2502 "midori-paths.c"
					gchar** _tmp57_;
					gint _tmp57__length1;
					gint _tmp58_;
					const gchar* _tmp59_;
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp57_ = str_array;
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp57__length1 = str_array_length1;
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp58_ = i;
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp59_ = _tmp57_[_tmp58_];
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp53_ = (const gchar*) _tmp59_;
#line 2517 "midori-paths.c"
				} else {
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
					_tmp53_ = "";
#line 2521 "midori-paths.c"
				}
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp60_ = ptr;
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				_tmp61_ = g_stpcpy (_tmp60_, _tmp53_);
#line 1105 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
				ptr = _tmp61_;
#line 2529 "midori-paths.c"
			}
		}
#line 1108 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp62_ = res;
#line 1108 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		res = NULL;
#line 1108 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		result = (gchar*) _tmp62_;
#line 1108 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		return result;
#line 2540 "midori-paths.c"
	} else {
		gchar* _tmp63_;
#line 1110 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp63_ = g_strdup ("");
#line 1110 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		result = _tmp63_;
#line 1110 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		return result;
#line 2549 "midori-paths.c"
	}
}


static gchar* string_replace (const gchar* self, const gchar* old, const gchar* replacement) {
	gchar* result = NULL;
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_ = FALSE;
	GError * _inner_error_ = NULL;
#line 1415 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, NULL);
#line 1415 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	g_return_val_if_fail (old != NULL, NULL);
#line 1415 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	g_return_val_if_fail (replacement != NULL, NULL);
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if ((*((gchar*) self)) == '\0') {
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp1_ = TRUE;
#line 2569 "midori-paths.c"
	} else {
		const gchar* _tmp2_;
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp2_ = old;
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp1_ = (*((gchar*) _tmp2_)) == '\0';
#line 2576 "midori-paths.c"
	}
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp1_) {
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp0_ = TRUE;
#line 2582 "midori-paths.c"
	} else {
		const gchar* _tmp3_;
		const gchar* _tmp4_;
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp3_ = old;
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp4_ = replacement;
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp0_ = g_strcmp0 (_tmp3_, _tmp4_) == 0;
#line 2592 "midori-paths.c"
	}
#line 1416 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (_tmp0_) {
#line 2596 "midori-paths.c"
		gchar* _tmp5_;
#line 1417 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp5_ = g_strdup (self);
#line 1417 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		result = _tmp5_;
#line 1417 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		return result;
#line 2604 "midori-paths.c"
	}
	{
		GRegex* regex = NULL;
		const gchar* _tmp6_;
		gchar* _tmp7_;
		gchar* _tmp8_;
		GRegex* _tmp9_;
		GRegex* _tmp10_;
		gchar* _tmp11_ = NULL;
		GRegex* _tmp12_;
		const gchar* _tmp13_;
		gchar* _tmp14_;
		gchar* _tmp15_;
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp6_ = old;
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp7_ = g_regex_escape_string (_tmp6_, -1);
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp8_ = _tmp7_;
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp9_ = g_regex_new (_tmp8_, 0, 0, &_inner_error_);
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp10_ = _tmp9_;
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_g_free0 (_tmp8_);
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		regex = _tmp10_;
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			if (_inner_error_->domain == G_REGEX_ERROR) {
#line 2636 "midori-paths.c"
				goto __catch5_g_regex_error;
			}
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			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 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			g_clear_error (&_inner_error_);
#line 1420 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			return NULL;
#line 2645 "midori-paths.c"
		}
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp12_ = regex;
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp13_ = replacement;
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp14_ = g_regex_replace_literal (_tmp12_, self, (gssize) -1, 0, _tmp13_, 0, &_inner_error_);
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp11_ = _tmp14_;
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			_g_regex_unref0 (regex);
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			if (_inner_error_->domain == G_REGEX_ERROR) {
#line 2661 "midori-paths.c"
				goto __catch5_g_regex_error;
			}
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			_g_regex_unref0 (regex);
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			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 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			g_clear_error (&_inner_error_);
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
			return NULL;
#line 2672 "midori-paths.c"
		}
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp15_ = _tmp11_;
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_tmp11_ = NULL;
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		result = _tmp15_;
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_g_free0 (_tmp11_);
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_g_regex_unref0 (regex);
#line 1421 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		return result;
#line 2686 "midori-paths.c"
	}
	goto __finally5;
	__catch5_g_regex_error:
	{
		GError* e = NULL;
#line 1419 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		e = _inner_error_;
#line 1419 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_inner_error_ = NULL;
#line 1423 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		g_assert_not_reached ();
#line 1419 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		_g_error_free0 (e);
#line 2700 "midori-paths.c"
	}
	__finally5:
#line 1419 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 1419 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		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 1419 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		g_clear_error (&_inner_error_);
#line 1419 "/usr/share/vala-0.38/vapi/glib-2.0.vapi"
		return NULL;
#line 2711 "midori-paths.c"
	}
}


gchar* midori_paths_get_command_line_str (gboolean for_display) {
	gchar* result = NULL;
	gchar** _tmp0_;
	gint _tmp0__length1;
	gboolean _tmp1_;
	gchar** _tmp8_;
	gint _tmp8__length1;
	gchar* _tmp9_;
	gchar* _tmp10_;
	gchar* _tmp11_;
	gchar* _tmp12_;
	gchar* _tmp13_;
	gchar* _tmp14_;
	gchar* _tmp15_;
	gchar* _tmp16_;
	gchar* _tmp17_;
	gchar* _tmp18_;
#line 351 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_command_line;
#line 351 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0__length1 = midori_paths_command_line_length1;
#line 351 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "command_line != null");
#line 352 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = for_display;
#line 352 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp1_) {
#line 2743 "midori-paths.c"
		gchar** _tmp2_;
		gint _tmp2__length1;
		gchar* _tmp3_;
		gchar* _tmp4_;
		const gchar* _tmp5_;
		gchar* _tmp6_;
		gchar* _tmp7_;
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp2_ = midori_paths_command_line;
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp2__length1 = midori_paths_command_line_length1;
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = _vala_g_strjoinv (" ", _tmp2_, _tmp2__length1);
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = _tmp3_;
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp5_ = g_get_home_dir ();
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp6_ = string_replace (_tmp4_, _tmp5_, "~");
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp7_ = _tmp6_;
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp4_);
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = _tmp7_;
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 2771 "midori-paths.c"
	}
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp8_ = midori_paths_command_line;
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp8__length1 = midori_paths_command_line_length1;
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp9_ = _vala_g_strjoinv (" ", _tmp8_, _tmp8__length1);
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp10_ = _tmp9_;
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp11_ = string_replace (_tmp10_, "--debug", "");
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp12_ = _tmp11_;
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp13_ = string_replace (_tmp12_, "-g", "");
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp14_ = _tmp13_;
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp15_ = string_replace (_tmp14_, "--diagnostic-dialog", "");
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp16_ = _tmp15_;
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp17_ = string_replace (_tmp16_, "-d", "");
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp18_ = _tmp17_;
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (_tmp16_);
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (_tmp14_);
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (_tmp12_);
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (_tmp10_);
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp18_;
#line 354 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 2809 "midori-paths.c"
}


gchar* midori_paths_get_lib_path (const gchar* package) {
	gchar* result = NULL;
	gchar** _tmp0_;
	gint _tmp0__length1;
	gchar* path = NULL;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	const gchar* _tmp4_;
	gint _tmp5_;
	const gchar* _tmp6_;
	gchar* _tmp15_;
#line 358 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (package != NULL, NULL);
#line 359 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_command_line;
#line 359 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0__length1 = midori_paths_command_line_length1;
#line 359 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "command_line != null");
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_exec_path;
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = package;
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = g_build_filename (_tmp1_, "lib", _tmp2_, NULL);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	path = _tmp3_;
#line 364 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp4_ = path;
#line 364 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp5_ = access (_tmp4_, F_OK);
#line 364 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp5_ == 0) {
#line 365 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = path;
#line 365 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 2851 "midori-paths.c"
	}
#line 367 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp6_ = package;
#line 367 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (g_strcmp0 (_tmp6_, PACKAGE_NAME) == 0) {
#line 2857 "midori-paths.c"
		const gchar* _tmp7_;
		GFile* _tmp8_;
		GFile* _tmp9_;
		gchar* _tmp10_;
		gchar* _tmp11_;
		gchar* _tmp12_;
		const gchar* _tmp13_;
		gint _tmp14_;
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp7_ = midori_paths_exec_path;
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp8_ = g_file_new_for_path (_tmp7_);
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp9_ = _tmp8_;
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp10_ = g_file_get_path (_tmp9_);
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp11_ = _tmp10_;
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp12_ = g_build_filename (_tmp11_, "extensions", NULL);
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (path);
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		path = _tmp12_;
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp11_);
#line 369 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_object_unref0 (_tmp9_);
#line 370 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp13_ = path;
#line 370 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp14_ = access (_tmp13_, F_OK);
#line 370 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		if (_tmp14_ == 0) {
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			result = path;
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			return result;
#line 2896 "midori-paths.c"
		}
	}
#line 374 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp15_ = g_build_filename (LIBDIR, PACKAGE_NAME, NULL);
#line 374 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp15_;
#line 374 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (path);
#line 374 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 2907 "midori-paths.c"
}


gchar* midori_paths_get_res_filename (const gchar* filename) {
	gchar* result = NULL;
	gchar** _tmp0_;
	gint _tmp0__length1;
	const gchar* _tmp1_;
	gchar* path = NULL;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	gchar* _tmp4_;
	const gchar* _tmp5_;
	gint _tmp6_;
	gchar* _tmp7_ = NULL;
	const gchar* _tmp8_;
	gchar* _tmp9_;
	gchar* _tmp12_;
#line 378 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (filename != NULL, NULL);
#line 379 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_command_line;
#line 379 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0__length1 = midori_paths_command_line_length1;
#line 379 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "command_line != null");
#line 380 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = filename;
#line 380 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (g_strcmp0 (_tmp1_, "") != 0, "filename != \"\"");
#line 384 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = midori_paths_exec_path;
#line 384 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = filename;
#line 384 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp4_ = g_build_filename (_tmp2_, "share", PACKAGE_NAME, "res", _tmp3_, NULL);
#line 384 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	path = _tmp4_;
#line 385 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp5_ = path;
#line 385 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp6_ = access (_tmp5_, F_OK);
#line 385 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp6_ == 0) {
#line 386 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = path;
#line 386 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 2956 "midori-paths.c"
	}
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp8_ = filename;
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp9_ = midori_paths_build_folder ("data", NULL, _tmp8_);
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp7_ = _tmp9_;
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp7_ == NULL) {
#line 2966 "midori-paths.c"
		const gchar* _tmp10_;
		gchar* _tmp11_;
#line 389 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp10_ = filename;
#line 389 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp11_ = g_build_filename (MDATADIR, PACKAGE_NAME, "res", _tmp10_, NULL);
#line 389 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp7_);
#line 389 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp7_ = _tmp11_;
#line 2977 "midori-paths.c"
	}
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp12_ = _tmp7_;
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp7_ = NULL;
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp12_;
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (_tmp7_);
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (path);
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 2991 "midori-paths.c"
}


gchar* midori_paths_build_folder (const gchar* folder, const gchar* middle, const gchar* filename) {
	gchar* result = NULL;
	GFile* parent = NULL;
	const gchar* _tmp0_;
	GFile* _tmp1_;
#line 394 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (folder != NULL, NULL);
#line 394 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (filename != NULL, NULL);
#line 396 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_exec_path;
#line 396 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = g_file_new_for_path (_tmp0_);
#line 396 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	parent = _tmp1_;
#line 397 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	while (TRUE) {
#line 3012 "midori-paths.c"
		GFile* _tmp2_;
		GFile* data = NULL;
		GFile* _tmp3_;
		const gchar* _tmp4_;
		GFile* _tmp5_;
		const gchar* _tmp6_;
		GFile* child = NULL;
		GFile* _tmp10_;
		const gchar* _tmp11_;
		GFile* _tmp12_;
		GFile* _tmp13_;
		gboolean _tmp14_;
		GFile* _tmp17_;
		GFile* _tmp18_;
#line 397 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp2_ = parent;
#line 397 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		if (!(_tmp2_ != NULL)) {
#line 397 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			break;
#line 3033 "midori-paths.c"
		}
#line 398 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = parent;
#line 398 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = folder;
#line 398 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp5_ = g_file_get_child (_tmp3_, _tmp4_);
#line 398 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		data = _tmp5_;
#line 399 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp6_ = middle;
#line 399 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		if (_tmp6_ != NULL) {
#line 3047 "midori-paths.c"
			GFile* _tmp7_;
			const gchar* _tmp8_;
			GFile* _tmp9_;
#line 400 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp7_ = data;
#line 400 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp8_ = middle;
#line 400 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp9_ = g_file_get_child (_tmp7_, _tmp8_);
#line 400 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_object_unref0 (data);
#line 400 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			data = _tmp9_;
#line 3061 "midori-paths.c"
		}
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp10_ = data;
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp11_ = filename;
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp12_ = g_file_get_child (_tmp10_, _tmp11_);
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		child = _tmp12_;
#line 402 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp13_ = child;
#line 402 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp14_ = g_file_query_exists (_tmp13_, NULL);
#line 402 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		if (_tmp14_) {
#line 3077 "midori-paths.c"
			GFile* _tmp15_;
			gchar* _tmp16_;
#line 403 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp15_ = child;
#line 403 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_tmp16_ = g_file_get_path (_tmp15_);
#line 403 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			result = _tmp16_;
#line 403 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_object_unref0 (child);
#line 403 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_object_unref0 (data);
#line 403 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			_g_object_unref0 (parent);
#line 403 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			return result;
#line 3094 "midori-paths.c"
		}
#line 404 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp17_ = parent;
#line 404 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp18_ = g_file_get_parent (_tmp17_);
#line 404 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_object_unref0 (parent);
#line 404 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		parent = _tmp18_;
#line 397 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_object_unref0 (child);
#line 397 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_object_unref0 (data);
#line 3108 "midori-paths.c"
	}
#line 406 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = NULL;
#line 406 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_object_unref0 (parent);
#line 406 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 3116 "midori-paths.c"
}


gchar* midori_paths_get_data_filename (const gchar* filename, gboolean res) {
	gchar* result = NULL;
	gchar** _tmp0_;
	gint _tmp0__length1;
	const gchar* _tmp1_ = NULL;
	gboolean _tmp2_;
	gchar* res1 = NULL;
	gchar* _tmp3_;
	const gchar* _tmp4_ = NULL;
	gboolean _tmp5_;
	gchar* res2 = NULL;
	gchar* _tmp6_;
	gchar* path = NULL;
	const gchar* _tmp7_;
	const gchar* _tmp8_;
	const gchar* _tmp9_;
	const gchar* _tmp10_;
	gchar* _tmp11_;
	const gchar* _tmp12_;
	gint _tmp13_;
	gchar** _tmp14_;
	gchar** _tmp15_;
	const gchar* _tmp23_;
	const gchar* _tmp24_;
	const gchar* _tmp25_;
	gchar* _tmp26_;
#line 412 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (filename != NULL, NULL);
#line 413 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_command_line;
#line 413 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0__length1 = midori_paths_command_line_length1;
#line 413 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "command_line != null");
#line 414 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = res;
#line 414 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp2_) {
#line 414 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp1_ = PACKAGE_NAME;
#line 3160 "midori-paths.c"
	} else {
#line 414 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp1_ = "";
#line 3164 "midori-paths.c"
	}
#line 414 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = g_strdup (_tmp1_);
#line 414 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	res1 = _tmp3_;
#line 415 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp5_ = res;
#line 415 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp5_) {
#line 415 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = "res";
#line 3176 "midori-paths.c"
	} else {
#line 415 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = "";
#line 3180 "midori-paths.c"
	}
#line 415 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp6_ = g_strdup (_tmp4_);
#line 415 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	res2 = _tmp6_;
#line 420 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp7_ = midori_paths_get_user_data_dir_for_reading ();
#line 420 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp8_ = res1;
#line 420 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp9_ = res2;
#line 420 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp10_ = filename;
#line 420 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp11_ = g_build_filename (_tmp7_, _tmp8_, _tmp9_, _tmp10_, NULL);
#line 420 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	path = _tmp11_;
#line 421 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp12_ = path;
#line 421 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp13_ = access (_tmp12_, F_OK);
#line 421 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp13_ == 0) {
#line 422 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = path;
#line 422 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (res2);
#line 422 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (res1);
#line 422 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 3212 "midori-paths.c"
	}
#line 424 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp15_ = _tmp14_ = g_get_system_data_dirs ();
#line 3216 "midori-paths.c"
	{
		gchar** data_dir_collection = NULL;
		gint data_dir_collection_length1 = 0;
		gint _data_dir_collection_size_ = 0;
		gint data_dir_it = 0;
#line 424 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		data_dir_collection = _tmp15_;
#line 424 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		data_dir_collection_length1 = _vala_array_length (_tmp14_);
#line 424 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		for (data_dir_it = 0; data_dir_it < _vala_array_length (_tmp14_); data_dir_it = data_dir_it + 1) {
#line 3228 "midori-paths.c"
			const gchar* data_dir = NULL;
#line 424 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			data_dir = data_dir_collection[data_dir_it];
#line 3232 "midori-paths.c"
			{
				const gchar* _tmp16_;
				const gchar* _tmp17_;
				const gchar* _tmp18_;
				const gchar* _tmp19_;
				gchar* _tmp20_;
				const gchar* _tmp21_;
				gint _tmp22_;
#line 425 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp16_ = data_dir;
#line 425 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp17_ = res1;
#line 425 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp18_ = res2;
#line 425 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp19_ = filename;
#line 425 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp20_ = g_build_filename (_tmp16_, _tmp17_, _tmp18_, _tmp19_, NULL);
#line 425 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (path);
#line 425 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				path = _tmp20_;
#line 426 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp21_ = path;
#line 426 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp22_ = access (_tmp21_, F_OK);
#line 426 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp22_ == 0) {
#line 427 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					result = path;
#line 427 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (res2);
#line 427 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_g_free0 (res1);
#line 427 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					return result;
#line 3269 "midori-paths.c"
				}
			}
		}
	}
#line 430 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp23_ = res1;
#line 430 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp24_ = res2;
#line 430 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp25_ = filename;
#line 430 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp26_ = g_build_filename (MDATADIR, _tmp23_, _tmp24_, _tmp25_, NULL);
#line 430 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp26_;
#line 430 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (path);
#line 430 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (res2);
#line 430 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (res1);
#line 430 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 3292 "midori-paths.c"
}


gchar* midori_paths_get_preset_filename (const gchar* folder, const gchar* filename) {
	gchar* result = NULL;
	const gchar* _tmp0_;
	gchar** _tmp1_;
	gchar** _tmp2_;
	const gchar* _tmp10_ = NULL;
	const gchar* _tmp11_;
	gchar* _tmp12_ = NULL;
	const gchar* _tmp13_;
	const gchar* _tmp14_;
	gchar* _tmp15_;
	gchar* _tmp18_;
#line 435 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	g_return_val_if_fail (filename != NULL, NULL);
#line 436 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_exec_path;
#line 436 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "exec_path != null");
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = _tmp1_ = g_get_system_config_dirs ();
#line 3316 "midori-paths.c"
	{
		gchar** config_dir_collection = NULL;
		gint config_dir_collection_length1 = 0;
		gint _config_dir_collection_size_ = 0;
		gint config_dir_it = 0;
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		config_dir_collection = _tmp2_;
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		config_dir_collection_length1 = _vala_array_length (_tmp1_);
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		for (config_dir_it = 0; config_dir_it < _vala_array_length (_tmp1_); config_dir_it = config_dir_it + 1) {
#line 3328 "midori-paths.c"
			const gchar* config_dir = NULL;
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
			config_dir = config_dir_collection[config_dir_it];
#line 3332 "midori-paths.c"
			{
				const gchar* _tmp3_ = NULL;
				const gchar* _tmp4_;
				gchar* path = NULL;
				const gchar* _tmp5_;
				const gchar* _tmp6_;
				gchar* _tmp7_;
				const gchar* _tmp8_;
				gint _tmp9_;
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp4_ = folder;
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp3_ = _tmp4_;
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp3_ == NULL) {
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					_tmp3_ = "";
#line 3350 "midori-paths.c"
				}
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp5_ = config_dir;
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp6_ = filename;
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp7_ = g_build_filename (_tmp5_, PACKAGE_NAME, _tmp3_, _tmp6_, NULL);
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				path = _tmp7_;
#line 443 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp8_ = path;
#line 443 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_tmp9_ = access (_tmp8_, F_OK);
#line 443 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				if (_tmp9_ == 0) {
#line 444 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					result = path;
#line 444 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
					return result;
#line 3370 "midori-paths.c"
				}
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
				_g_free0 (path);
#line 3374 "midori-paths.c"
			}
		}
	}
#line 448 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp11_ = folder;
#line 448 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp10_ = _tmp11_;
#line 448 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp10_ == NULL) {
#line 448 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp10_ = "";
#line 3386 "midori-paths.c"
	}
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp13_ = folder;
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp14_ = filename;
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp15_ = midori_paths_build_folder ("config", _tmp13_, _tmp14_);
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp12_ = _tmp15_;
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp12_ == NULL) {
#line 3398 "midori-paths.c"
		const gchar* _tmp16_;
		gchar* _tmp17_;
#line 448 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp16_ = filename;
#line 448 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp17_ = g_build_filename (SYSCONFDIR, "xdg", PACKAGE_NAME, _tmp10_, _tmp16_, NULL);
#line 448 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_free0 (_tmp12_);
#line 448 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp12_ = _tmp17_;
#line 3409 "midori-paths.c"
	}
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp18_ = _tmp12_;
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp12_ = NULL;
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = _tmp18_;
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (_tmp12_);
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 3421 "midori-paths.c"
}


void midori_paths_clear_icons (void) {
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	WebKitFaviconDatabase* _tmp2_;
	const gchar* _tmp3_;
	gchar* _tmp4_;
	gchar* _tmp5_;
#line 453 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = midori_paths_cache_dir;
#line 453 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp0_ != NULL, "cache_dir != null");
#line 454 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_paths_user_data_dir;
#line 454 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_vala_assert (_tmp1_ != NULL, "user_data_dir != null");
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = webkit_get_favicon_database ();
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	webkit_favicon_database_clear (_tmp2_);
#line 461 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp3_ = midori_paths_user_data_dir;
#line 461 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp4_ = g_build_filename (_tmp3_, "webkit", "icondatabase", NULL);
#line 461 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp5_ = _tmp4_;
#line 461 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	midori_paths_remove_path (_tmp5_);
#line 461 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_free0 (_tmp5_);
#line 3454 "midori-paths.c"
}


/**
         * Looks up a pixbuf for the given @uri. If @widget is given a generic
         * file icon is used in case there's no icon.
         *
         * Deprecated: 0.5.8: Use Midori.URI.Icon or Midori.URI.get_icon instead.
         **/
GdkPixbuf* midori_paths_get_icon (const gchar* uri, GtkWidget* widget) {
	GdkPixbuf* result = NULL;
	const gchar* _tmp0_;
	gboolean _tmp1_;
	gint icon_width = 0;
	gint icon_height = 0;
	GtkWidget* _tmp2_;
	GdkPixbuf* pixbuf = NULL;
	WebKitFaviconDatabase* _tmp8_;
	const gchar* _tmp9_;
	gint _tmp10_;
	gint _tmp11_;
	GdkPixbuf* _tmp12_;
	GdkPixbuf* _tmp13_;
	GtkWidget* _tmp14_;
#line 471 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp0_ = uri;
#line 471 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp1_ = midori_uri_is_resource (_tmp0_);
#line 471 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (!_tmp1_) {
#line 472 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = NULL;
#line 472 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 3489 "midori-paths.c"
	}
#line 473 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	icon_width = 16;
#line 473 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	icon_height = 16;
#line 474 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp2_ = widget;
#line 474 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp2_ != NULL) {
#line 3499 "midori-paths.c"
		GtkWidget* _tmp3_;
		GtkSettings* _tmp4_;
		gint _tmp5_ = 0;
		gint _tmp6_ = 0;
#line 475 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp3_ = widget;
#line 475 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp4_ = gtk_widget_get_settings (_tmp3_);
#line 475 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		gtk_icon_size_lookup_for_settings (_tmp4_, GTK_ICON_SIZE_MENU, &_tmp5_, &_tmp6_);
#line 475 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		icon_width = _tmp5_;
#line 475 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		icon_height = _tmp6_;
#line 3514 "midori-paths.c"
	} else {
		gint _tmp7_;
#line 478 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		icon_height = 0;
#line 478 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp7_ = icon_height;
#line 478 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		icon_width = _tmp7_;
#line 3523 "midori-paths.c"
	}
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp8_ = webkit_get_favicon_database ();
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp9_ = uri;
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp10_ = icon_width;
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp11_ = icon_height;
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp12_ = webkit_favicon_database_try_get_favicon_pixbuf (_tmp8_, _tmp9_, (guint) _tmp10_, (guint) _tmp11_);
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	pixbuf = _tmp12_;
#line 484 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp13_ = pixbuf;
#line 484 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp13_ != NULL) {
#line 485 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = pixbuf;
#line 485 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 3545 "midori-paths.c"
	}
#line 487 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_tmp14_ = widget;
#line 487 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	if (_tmp14_ != NULL) {
#line 3551 "midori-paths.c"
		GtkWidget* _tmp15_;
		GdkPixbuf* _tmp16_;
#line 488 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp15_ = widget;
#line 488 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_tmp16_ = gtk_widget_render_icon (_tmp15_, GTK_STOCK_FILE, GTK_ICON_SIZE_MENU, NULL);
#line 488 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		result = _tmp16_;
#line 488 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		_g_object_unref0 (pixbuf);
#line 488 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
		return result;
#line 3564 "midori-paths.c"
	}
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	result = NULL;
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	_g_object_unref0 (pixbuf);
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/katze/midori-paths.vala"
	return result;
#line 3572 "midori-paths.c"
}


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);
}


static gint _vala_array_length (gpointer array) {
	int length;
	length = 0;
	if (array) {
		while (((gpointer*) array)[length]) {
			length++;
		}
	}
	return length;
}



