/* gnome-ask-password-agent.c generated by valac 0.15.1, the Vala compiler
 * generated from gnome-ask-password-agent.vala, do not modify */


#include <glib.h>
#include <glib-object.h>
#include <time.h>
#include <gtk/gtk.h>
#include <stdlib.h>
#include <string.h>
#include <gio/gio.h>
#include <stdio.h>
#include <libnotify/notify.h>
#include <gio/gunixoutputstream.h>


#define TYPE_PASSWORD_DIALOG (password_dialog_get_type ())
#define PASSWORD_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PASSWORD_DIALOG, PasswordDialog))
#define PASSWORD_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PASSWORD_DIALOG, PasswordDialogClass))
#define IS_PASSWORD_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PASSWORD_DIALOG))
#define IS_PASSWORD_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PASSWORD_DIALOG))
#define PASSWORD_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PASSWORD_DIALOG, PasswordDialogClass))

typedef struct _PasswordDialog PasswordDialog;
typedef struct _PasswordDialogClass PasswordDialogClass;
typedef struct _PasswordDialogPrivate PasswordDialogPrivate;
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))

#define TYPE_MY_STATUS_ICON (my_status_icon_get_type ())
#define MY_STATUS_ICON(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_MY_STATUS_ICON, MyStatusIcon))
#define MY_STATUS_ICON_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_MY_STATUS_ICON, MyStatusIconClass))
#define IS_MY_STATUS_ICON(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_MY_STATUS_ICON))
#define IS_MY_STATUS_ICON_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_MY_STATUS_ICON))
#define MY_STATUS_ICON_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_MY_STATUS_ICON, MyStatusIconClass))

typedef struct _MyStatusIcon MyStatusIcon;
typedef struct _MyStatusIconClass MyStatusIconClass;
typedef struct _MyStatusIconPrivate MyStatusIconPrivate;
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
#define _g_key_file_free0(var) ((var == NULL) ? NULL : (var = (g_key_file_free (var), NULL)))

struct _PasswordDialog {
	GtkDialog parent_instance;
	PasswordDialogPrivate * priv;
	GtkEntry* entry;
};

struct _PasswordDialogClass {
	GtkDialogClass parent_class;
};

struct _MyStatusIcon {
	GtkStatusIcon parent_instance;
	MyStatusIconPrivate * priv;
};

struct _MyStatusIconClass {
	GtkStatusIconClass parent_class;
};

struct _MyStatusIconPrivate {
	GFile* directory;
	GFile* current;
	GFileMonitor* file_monitor;
	gchar* message;
	gchar* icon;
	gchar* socket;
	PasswordDialog* password_dialog;
};


static gpointer password_dialog_parent_class = NULL;
static gpointer my_status_icon_parent_class = NULL;

gint clock_gettime (gint id, struct timespec* ts);
GType password_dialog_get_type (void) G_GNUC_CONST;
enum  {
	PASSWORD_DIALOG_DUMMY_PROPERTY
};
PasswordDialog* password_dialog_new (const gchar* message, const gchar* icon);
PasswordDialog* password_dialog_construct (GType object_type, const gchar* message, const gchar* icon);
void password_dialog_on_entry_activated (PasswordDialog* self);
static void _password_dialog_on_entry_activated_gtk_entry_activate (GtkEntry* _sender, gpointer self);
static void password_dialog_finalize (GObject* obj);
GType my_status_icon_get_type (void) G_GNUC_CONST;
#define MY_STATUS_ICON_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_MY_STATUS_ICON, MyStatusIconPrivate))
enum  {
	MY_STATUS_ICON_DUMMY_PROPERTY
};
MyStatusIcon* my_status_icon_new (GError** error);
MyStatusIcon* my_status_icon_construct (GType object_type, GError** error);
static void my_status_icon_file_monitor_changed (MyStatusIcon* self, GFile* file, GFile* other_file, GFileMonitorEvent event_type);
static void _my_status_icon_file_monitor_changed_g_file_monitor_changed (GFileMonitor* _sender, GFile* file, GFile* other_file, GFileMonitorEvent event_type, gpointer self);
static void my_status_icon_look_for_password (MyStatusIcon* self, GError** error);
static void my_status_icon_status_icon_activate (MyStatusIcon* self);
static void _my_status_icon_status_icon_activate_gtk_status_icon_activate (GtkStatusIcon* _sender, gpointer self);
void show_error (const gchar* e);
static gboolean my_status_icon_load_password (MyStatusIcon* self, GError** error);
static void my_status_icon_finalize (GObject* obj);
gint _vala_main (gchar** args, int args_length1);
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);

const GOptionEntry entries[1] = {{NULL}};

/***
  This file is part of systemd.

  Copyright 2010 Lennart Poettering

  systemd is free software; you can redistribute it and/or modify it
  under the terms of the GNU General Public License as published by
  the Free Software Foundation; either version 2 of the License, or
  (at your option) any later version.

  systemd is distributed in the hope that it will be useful, but
  WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
static gpointer _g_object_ref0 (gpointer self) {
#line 43 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	return self ? g_object_ref (self) : NULL;
#line 129 "gnome-ask-password-agent.c"
}


static void _password_dialog_on_entry_activated_gtk_entry_activate (GtkEntry* _sender, gpointer self) {
#line 63 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	password_dialog_on_entry_activated (self);
#line 136 "gnome-ask-password-agent.c"
}


PasswordDialog* password_dialog_construct (GType object_type, const gchar* message, const gchar* icon) {
	PasswordDialog * self = NULL;
	const gchar* _tmp0_;
	GtkWidget* _tmp1_ = NULL;
	GtkContainer* _tmp2_;
	GtkContainer* content;
	GtkHBox* _tmp3_;
	GtkBox* _tmp4_;
	GtkBox* hbox;
	const gchar* _tmp5_;
	GtkImage* _tmp6_;
	GtkImage* _tmp7_;
	GtkImage* image;
	GtkVBox* _tmp8_;
	GtkBox* _tmp9_;
	GtkBox* vbox;
	const gchar* _tmp10_;
	GtkLabel* _tmp11_;
	GtkLabel* _tmp12_;
	GtkLabel* label;
	GtkEntry* _tmp13_;
	GtkEntry* _tmp14_;
	GtkEntry* _tmp15_;
	GtkEntry* _tmp16_;
	GtkEntry* _tmp17_;
	GtkEntry* _tmp18_;
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_return_val_if_fail (message != NULL, NULL);
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_return_val_if_fail (icon != NULL, NULL);
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self = (PasswordDialog*) g_object_new (object_type, NULL);
#line 34 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_window_set_title ((GtkWindow*) self, "System Password");
#line 35 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_dialog_set_has_separator ((GtkDialog*) self, FALSE);
#line 36 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_container_set_border_width ((GtkContainer*) self, (guint) 8);
#line 37 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_dialog_set_default_response ((GtkDialog*) self, (gint) GTK_RESPONSE_OK);
#line 38 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp0_ = icon;
#line 38 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_window_set_icon_name ((GtkWindow*) self, _tmp0_);
#line 40 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_dialog_add_button ((GtkDialog*) self, GTK_STOCK_CANCEL, (gint) GTK_RESPONSE_CANCEL);
#line 41 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_dialog_add_button ((GtkDialog*) self, GTK_STOCK_OK, (gint) GTK_RESPONSE_OK);
#line 43 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp1_ = gtk_dialog_get_content_area ((GtkDialog*) self);
#line 43 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp2_ = _g_object_ref0 (GTK_CONTAINER (_tmp1_));
#line 43 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	content = _tmp2_;
#line 45 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp3_ = (GtkHBox*) gtk_hbox_new (FALSE, 16);
#line 45 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp4_ = (GtkBox*) g_object_ref_sink (_tmp3_);
#line 45 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	hbox = _tmp4_;
#line 46 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_container_set_border_width ((GtkContainer*) hbox, (guint) 8);
#line 47 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_container_add (content, (GtkWidget*) hbox);
#line 49 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp5_ = icon;
#line 49 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp6_ = (GtkImage*) gtk_image_new_from_icon_name (_tmp5_, GTK_ICON_SIZE_DIALOG);
#line 49 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp7_ = g_object_ref_sink (_tmp6_);
#line 49 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	image = _tmp7_;
#line 50 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_box_pack_start (hbox, (GtkWidget*) image, FALSE, FALSE, (guint) 0);
#line 52 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp8_ = (GtkVBox*) gtk_vbox_new (FALSE, 8);
#line 52 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp9_ = (GtkBox*) g_object_ref_sink (_tmp8_);
#line 52 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	vbox = _tmp9_;
#line 53 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_box_pack_start (hbox, (GtkWidget*) vbox, TRUE, TRUE, (guint) 0);
#line 55 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp10_ = message;
#line 55 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp11_ = (GtkLabel*) gtk_label_new (_tmp10_);
#line 55 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp12_ = g_object_ref_sink (_tmp11_);
#line 55 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	label = _tmp12_;
#line 56 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_box_pack_start (vbox, (GtkWidget*) label, FALSE, FALSE, (guint) 0);
#line 58 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp13_ = (GtkEntry*) gtk_entry_new ();
#line 58 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp14_ = g_object_ref_sink (_tmp13_);
#line 58 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->entry);
#line 58 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self->entry = _tmp14_;
#line 59 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp15_ = self->entry;
#line 59 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_entry_set_visibility (_tmp15_, FALSE);
#line 60 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp16_ = self->entry;
#line 60 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_entry_set_activates_default (_tmp16_, TRUE);
#line 61 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp17_ = self->entry;
#line 61 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_box_pack_start (vbox, (GtkWidget*) _tmp17_, FALSE, FALSE, (guint) 0);
#line 63 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp18_ = self->entry;
#line 63 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_signal_connect_object (_tmp18_, "activate", (GCallback) _password_dialog_on_entry_activated_gtk_entry_activate, self, 0);
#line 65 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_widget_show_all ((GtkWidget*) self);
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (label);
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (vbox);
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (image);
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (hbox);
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (content);
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	return self;
#line 270 "gnome-ask-password-agent.c"
}


PasswordDialog* password_dialog_new (const gchar* message, const gchar* icon) {
#line 33 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	return password_dialog_construct (TYPE_PASSWORD_DIALOG, message, icon);
#line 277 "gnome-ask-password-agent.c"
}


void password_dialog_on_entry_activated (PasswordDialog* self) {
#line 68 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_return_if_fail (self != NULL);
#line 69 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_dialog_response ((GtkDialog*) self, (gint) GTK_RESPONSE_OK);
#line 286 "gnome-ask-password-agent.c"
}


static void password_dialog_class_init (PasswordDialogClass * klass) {
#line 29 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	password_dialog_parent_class = g_type_class_peek_parent (klass);
#line 29 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	G_OBJECT_CLASS (klass)->finalize = password_dialog_finalize;
#line 295 "gnome-ask-password-agent.c"
}


static void password_dialog_instance_init (PasswordDialog * self) {
}


static void password_dialog_finalize (GObject* obj) {
	PasswordDialog * self;
#line 29 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self = PASSWORD_DIALOG (obj);
#line 31 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->entry);
#line 29 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	G_OBJECT_CLASS (password_dialog_parent_class)->finalize (obj);
#line 311 "gnome-ask-password-agent.c"
}


GType password_dialog_get_type (void) {
	static volatile gsize password_dialog_type_id__volatile = 0;
	if (g_once_init_enter (&password_dialog_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (PasswordDialogClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) password_dialog_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (PasswordDialog), 0, (GInstanceInitFunc) password_dialog_instance_init, NULL };
		GType password_dialog_type_id;
		password_dialog_type_id = g_type_register_static (GTK_TYPE_DIALOG, "PasswordDialog", &g_define_type_info, 0);
		g_once_init_leave (&password_dialog_type_id__volatile, password_dialog_type_id);
	}
	return password_dialog_type_id__volatile;
}


static void _my_status_icon_file_monitor_changed_g_file_monitor_changed (GFileMonitor* _sender, GFile* file, GFile* other_file, GFileMonitorEvent event_type, gpointer self) {
#line 91 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	my_status_icon_file_monitor_changed (self, file, other_file, event_type);
#line 330 "gnome-ask-password-agent.c"
}


static void _my_status_icon_status_icon_activate_gtk_status_icon_activate (GtkStatusIcon* _sender, gpointer self) {
#line 96 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	my_status_icon_status_icon_activate (self);
#line 337 "gnome-ask-password-agent.c"
}


MyStatusIcon* my_status_icon_construct (GType object_type, GError** error) {
	MyStatusIcon * self = NULL;
	GFile* _tmp0_ = NULL;
	GFile* _tmp1_;
	GFileMonitor* _tmp2_ = NULL;
	GFileMonitor* _tmp3_;
	GFileMonitor* _tmp4_;
	GError * _inner_error_ = NULL;
#line 86 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self = (MyStatusIcon*) g_object_new (object_type, "icon-name", "dialog-password", NULL);
#line 87 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_status_icon_set_title ((GtkStatusIcon*) self, "System Password Request");
#line 89 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp0_ = g_file_new_for_path ("/run/systemd/ask-password/");
#line 89 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->priv->directory);
#line 89 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self->priv->directory = _tmp0_;
#line 90 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp1_ = self->priv->directory;
#line 90 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp2_ = g_file_monitor_directory (_tmp1_, 0, NULL, &_inner_error_);
#line 90 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp3_ = _tmp2_;
#line 90 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_inner_error_ != NULL) {
#line 90 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_propagate_error (error, _inner_error_);
#line 90 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_object_unref0 (self);
#line 90 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return NULL;
#line 373 "gnome-ask-password-agent.c"
	}
#line 90 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->priv->file_monitor);
#line 90 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self->priv->file_monitor = _tmp3_;
#line 91 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp4_ = self->priv->file_monitor;
#line 91 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_signal_connect_object (_tmp4_, "changed", (GCallback) _my_status_icon_file_monitor_changed_g_file_monitor_changed, self, 0);
#line 93 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->priv->current);
#line 93 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self->priv->current = NULL;
#line 94 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	my_status_icon_look_for_password (self, &_inner_error_);
#line 94 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_inner_error_ != NULL) {
#line 94 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_propagate_error (error, _inner_error_);
#line 94 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_object_unref0 (self);
#line 94 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return NULL;
#line 397 "gnome-ask-password-agent.c"
	}
#line 96 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_signal_connect_object ((GtkStatusIcon*) self, "activate", (GCallback) _my_status_icon_status_icon_activate_gtk_status_icon_activate, self, 0);
#line 85 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	return self;
#line 403 "gnome-ask-password-agent.c"
}


MyStatusIcon* my_status_icon_new (GError** error) {
#line 85 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	return my_status_icon_construct (TYPE_MY_STATUS_ICON, error);
#line 410 "gnome-ask-password-agent.c"
}


static void my_status_icon_file_monitor_changed (MyStatusIcon* self, GFile* file, GFile* other_file, GFileMonitorEvent event_type) {
	GFile* _tmp0_;
	gchar* _tmp1_ = NULL;
	gchar* _tmp2_;
	gboolean _tmp3_ = FALSE;
	gboolean _tmp4_;
	gboolean _tmp5_ = FALSE;
	GFileMonitorEvent _tmp6_;
	gboolean _tmp8_;
	GError * _inner_error_ = NULL;
#line 99 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_return_if_fail (self != NULL);
#line 99 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_return_if_fail (file != NULL);
#line 101 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp0_ = file;
#line 101 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp1_ = g_file_get_basename (_tmp0_);
#line 101 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp2_ = _tmp1_;
#line 101 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp3_ = g_str_has_prefix (_tmp2_, "ask.");
#line 101 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp4_ = !_tmp3_;
#line 101 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_free0 (_tmp2_);
#line 101 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp4_) {
#line 102 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return;
#line 444 "gnome-ask-password-agent.c"
	}
#line 104 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp6_ = event_type;
#line 104 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp6_ == G_FILE_MONITOR_EVENT_CREATED) {
#line 104 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp5_ = TRUE;
#line 452 "gnome-ask-password-agent.c"
	} else {
		GFileMonitorEvent _tmp7_;
#line 105 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp7_ = event_type;
#line 105 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp5_ = _tmp7_ == G_FILE_MONITOR_EVENT_DELETED;
#line 459 "gnome-ask-password-agent.c"
	}
#line 104 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp8_ = _tmp5_;
#line 104 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp8_) {
#line 465 "gnome-ask-password-agent.c"
		{
#line 107 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			my_status_icon_look_for_password (self, &_inner_error_);
#line 107 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			if (_inner_error_ != NULL) {
#line 471 "gnome-ask-password-agent.c"
				goto __catch0_g_error;
			}
		}
		goto __finally0;
		__catch0_g_error:
		{
			GError* e = NULL;
			GError* _tmp9_;
			const gchar* _tmp10_;
#line 106 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			e = _inner_error_;
#line 106 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_inner_error_ = NULL;
#line 109 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp9_ = e;
#line 109 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp10_ = _tmp9_->message;
#line 109 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			show_error (_tmp10_);
#line 106 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_error_free0 (e);
#line 493 "gnome-ask-password-agent.c"
		}
		__finally0:
#line 106 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 106 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.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 106 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			g_clear_error (&_inner_error_);
#line 106 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			return;
#line 504 "gnome-ask-password-agent.c"
		}
	}
}


static void my_status_icon_look_for_password (MyStatusIcon* self, GError** error) {
	GFile* _tmp0_;
	GFile* _tmp5_;
	GFile* _tmp21_;
	GError * _inner_error_ = NULL;
#line 114 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_return_if_fail (self != NULL);
#line 116 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp0_ = self->priv->current;
#line 116 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp0_ != NULL) {
#line 521 "gnome-ask-password-agent.c"
		GFile* _tmp1_;
		gboolean _tmp2_ = FALSE;
#line 117 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp1_ = self->priv->current;
#line 117 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp2_ = g_file_query_exists (_tmp1_, NULL);
#line 117 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (!_tmp2_) {
#line 530 "gnome-ask-password-agent.c"
			PasswordDialog* _tmp3_;
#line 118 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_object_unref0 (self->priv->current);
#line 118 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			self->priv->current = NULL;
#line 119 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp3_ = self->priv->password_dialog;
#line 119 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			if (_tmp3_ != NULL) {
#line 540 "gnome-ask-password-agent.c"
				PasswordDialog* _tmp4_;
#line 120 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				_tmp4_ = self->priv->password_dialog;
#line 120 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				gtk_dialog_response ((GtkDialog*) _tmp4_, (gint) GTK_RESPONSE_REJECT);
#line 546 "gnome-ask-password-agent.c"
			}
		}
	}
#line 124 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp5_ = self->priv->current;
#line 124 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp5_ == NULL) {
#line 554 "gnome-ask-password-agent.c"
		GFile* _tmp6_;
		GFileEnumerator* _tmp7_ = NULL;
		GFileEnumerator* enumerator;
		GFileInfo* i = NULL;
#line 125 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp6_ = self->priv->directory;
#line 125 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp7_ = g_file_enumerate_children (_tmp6_, "standard::name", G_FILE_QUERY_INFO_NOFOLLOW_SYMLINKS, NULL, &_inner_error_);
#line 125 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		enumerator = _tmp7_;
#line 125 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 125 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			g_propagate_error (error, _inner_error_);
#line 125 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			return;
#line 571 "gnome-ask-password-agent.c"
		}
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		while (TRUE) {
#line 575 "gnome-ask-password-agent.c"
			GFileEnumerator* _tmp8_;
			GFileInfo* _tmp9_ = NULL;
			GFileInfo* _tmp10_;
			GFileInfo* _tmp11_;
			GFileInfo* _tmp12_;
			const gchar* _tmp13_ = NULL;
			gboolean _tmp14_ = FALSE;
			GFile* _tmp15_;
			GFileInfo* _tmp16_;
			const gchar* _tmp17_ = NULL;
			GFile* _tmp18_ = NULL;
			gboolean _tmp19_ = FALSE;
			gboolean _tmp20_;
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp8_ = enumerator;
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp9_ = g_file_enumerator_next_file (_tmp8_, NULL, &_inner_error_);
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp10_ = _tmp9_;
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			if (_inner_error_ != NULL) {
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				g_propagate_error (error, _inner_error_);
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				_g_object_unref0 (i);
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				_g_object_unref0 (enumerator);
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				return;
#line 605 "gnome-ask-password-agent.c"
			}
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_object_unref0 (i);
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			i = _tmp10_;
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp11_ = i;
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			if (!(_tmp11_ != NULL)) {
#line 128 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				break;
#line 617 "gnome-ask-password-agent.c"
			}
#line 129 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp12_ = i;
#line 129 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp13_ = g_file_info_get_name (_tmp12_);
#line 129 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp14_ = g_str_has_prefix (_tmp13_, "ask.");
#line 129 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			if (!_tmp14_) {
#line 130 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				continue;
#line 629 "gnome-ask-password-agent.c"
			}
#line 132 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp15_ = self->priv->directory;
#line 132 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp16_ = i;
#line 132 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp17_ = g_file_info_get_name (_tmp16_);
#line 132 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp18_ = g_file_get_child (_tmp15_, _tmp17_);
#line 132 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_object_unref0 (self->priv->current);
#line 132 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			self->priv->current = _tmp18_;
#line 134 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp19_ = my_status_icon_load_password (self, &_inner_error_);
#line 134 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp20_ = _tmp19_;
#line 134 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			if (_inner_error_ != NULL) {
#line 134 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				g_propagate_error (error, _inner_error_);
#line 134 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				_g_object_unref0 (i);
#line 134 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				_g_object_unref0 (enumerator);
#line 134 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				return;
#line 657 "gnome-ask-password-agent.c"
			}
#line 134 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			if (_tmp20_) {
#line 135 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
				break;
#line 663 "gnome-ask-password-agent.c"
			}
#line 137 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_object_unref0 (self->priv->current);
#line 137 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			self->priv->current = NULL;
#line 669 "gnome-ask-password-agent.c"
		}
#line 124 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_object_unref0 (i);
#line 124 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_object_unref0 (enumerator);
#line 675 "gnome-ask-password-agent.c"
	}
#line 141 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp21_ = self->priv->current;
#line 141 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp21_ == NULL) {
#line 142 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		gtk_status_icon_set_visible ((GtkStatusIcon*) self, FALSE);
#line 683 "gnome-ask-password-agent.c"
	}
}


static gboolean my_status_icon_load_password (MyStatusIcon* self, GError** error) {
	gboolean result = FALSE;
	GKeyFile* _tmp0_;
	GKeyFile* key_file;
	const gchar* _tmp28_;
	const gchar* _tmp33_;
	const gchar* _tmp34_;
	const gchar* _tmp35_;
	const gchar* _tmp36_;
	const gchar* _tmp37_;
	NotifyNotification* _tmp38_;
	NotifyNotification* n;
	NotifyNotification* _tmp39_;
	NotifyNotification* _tmp40_;
	GError * _inner_error_ = NULL;
#line 145 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 147 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp0_ = g_key_file_new ();
#line 147 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	key_file = _tmp0_;
#line 709 "gnome-ask-password-agent.c"
	{
		struct timespec ts = {0};
		GKeyFile* _tmp1_;
		GFile* _tmp2_;
		gchar* _tmp3_ = NULL;
		gchar* _tmp4_;
		GKeyFile* _tmp5_;
		gchar* _tmp6_ = NULL;
		gchar* not_after_as_string;
		struct timespec _tmp7_ = {0};
		struct timespec _tmp8_;
		time_t _tmp9_;
		struct timespec _tmp10_;
		glong _tmp11_;
		guint64 now;
		guint64 not_after = 0ULL;
		const gchar* _tmp12_;
		gint _tmp13_ = 0;
		gboolean _tmp14_ = FALSE;
		guint64 _tmp15_;
		gboolean _tmp18_;
		GKeyFile* _tmp19_;
		gchar* _tmp20_ = NULL;
		gchar* _tmp21_;
#line 152 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp1_ = key_file;
#line 152 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp2_ = self->priv->current;
#line 152 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp3_ = g_file_get_path (_tmp2_);
#line 152 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp4_ = _tmp3_;
#line 152 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_key_file_load_from_file (_tmp1_, _tmp4_, G_KEY_FILE_NONE, &_inner_error_);
#line 152 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (_tmp4_);
#line 152 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 748 "gnome-ask-password-agent.c"
			goto __catch1_g_error;
		}
#line 154 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp5_ = key_file;
#line 154 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp6_ = g_key_file_get_string (_tmp5_, "Ask", "NotAfter", &_inner_error_);
#line 154 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		not_after_as_string = _tmp6_;
#line 154 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 759 "gnome-ask-password-agent.c"
			goto __catch1_g_error;
		}
#line 156 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		clock_gettime (1, &_tmp7_);
#line 156 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		ts = _tmp7_;
#line 157 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp8_ = ts;
#line 157 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp9_ = _tmp8_.tv_sec;
#line 157 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp10_ = ts;
#line 157 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp11_ = _tmp10_.tv_nsec;
#line 157 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		now = (guint64) ((_tmp9_ * 1000000) + (_tmp11_ / 1000));
#line 160 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp12_ = not_after_as_string;
#line 160 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp13_ = sscanf (_tmp12_, "%llu", &not_after);
#line 160 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_tmp13_ != 1) {
#line 161 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			result = FALSE;
#line 161 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_free0 (not_after_as_string);
#line 161 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_key_file_free0 (key_file);
#line 161 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			return result;
#line 790 "gnome-ask-password-agent.c"
		}
#line 163 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp15_ = not_after;
#line 163 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_tmp15_ > ((guint64) 0)) {
#line 796 "gnome-ask-password-agent.c"
			guint64 _tmp16_;
			guint64 _tmp17_;
#line 163 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp16_ = not_after;
#line 163 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp17_ = now;
#line 163 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp14_ = _tmp16_ < _tmp17_;
#line 805 "gnome-ask-password-agent.c"
		} else {
#line 163 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp14_ = FALSE;
#line 809 "gnome-ask-password-agent.c"
		}
#line 163 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp18_ = _tmp14_;
#line 163 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_tmp18_) {
#line 164 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			result = FALSE;
#line 164 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_free0 (not_after_as_string);
#line 164 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_key_file_free0 (key_file);
#line 164 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			return result;
#line 823 "gnome-ask-password-agent.c"
		}
#line 166 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp19_ = key_file;
#line 166 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp20_ = g_key_file_get_string (_tmp19_, "Ask", "Socket", &_inner_error_);
#line 166 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp21_ = _tmp20_;
#line 166 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 166 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_free0 (not_after_as_string);
#line 835 "gnome-ask-password-agent.c"
			goto __catch1_g_error;
		}
#line 166 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (self->priv->socket);
#line 166 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		self->priv->socket = _tmp21_;
#line 149 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (not_after_as_string);
#line 844 "gnome-ask-password-agent.c"
	}
	goto __finally1;
	__catch1_g_error:
	{
		GError* e = NULL;
#line 149 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		e = _inner_error_;
#line 149 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_inner_error_ = NULL;
#line 168 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		result = FALSE;
#line 168 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_error_free0 (e);
#line 168 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_key_file_free0 (key_file);
#line 168 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return result;
#line 862 "gnome-ask-password-agent.c"
	}
	__finally1:
#line 149 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_inner_error_ != NULL) {
#line 149 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_propagate_error (error, _inner_error_);
#line 149 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_key_file_free0 (key_file);
#line 149 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return FALSE;
#line 873 "gnome-ask-password-agent.c"
	}
	{
		GKeyFile* _tmp22_;
		gchar* _tmp23_ = NULL;
		gchar* _tmp24_;
		gchar* _tmp25_;
		gchar* _tmp26_ = NULL;
#line 172 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp22_ = key_file;
#line 172 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp23_ = g_key_file_get_string (_tmp22_, "Ask", "Message", &_inner_error_);
#line 172 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp24_ = _tmp23_;
#line 172 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 889 "gnome-ask-password-agent.c"
			goto __catch2_g_error;
		}
#line 172 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp25_ = _tmp24_;
#line 172 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp26_ = g_strcompress (_tmp25_);
#line 172 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (self->priv->message);
#line 172 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		self->priv->message = _tmp26_;
#line 172 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (_tmp25_);
#line 902 "gnome-ask-password-agent.c"
	}
	goto __finally2;
	__catch2_g_error:
	{
		GError* e = NULL;
		gchar* _tmp27_;
#line 171 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		e = _inner_error_;
#line 171 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_inner_error_ = NULL;
#line 174 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp27_ = g_strdup ("Please Enter System Password!");
#line 174 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (self->priv->message);
#line 174 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		self->priv->message = _tmp27_;
#line 171 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_error_free0 (e);
#line 921 "gnome-ask-password-agent.c"
	}
	__finally2:
#line 171 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_inner_error_ != NULL) {
#line 171 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_propagate_error (error, _inner_error_);
#line 171 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_key_file_free0 (key_file);
#line 171 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return FALSE;
#line 932 "gnome-ask-password-agent.c"
	}
#line 177 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp28_ = self->priv->message;
#line 177 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_status_icon_set_tooltip_text ((GtkStatusIcon*) self, _tmp28_);
#line 938 "gnome-ask-password-agent.c"
	{
		GKeyFile* _tmp29_;
		gchar* _tmp30_ = NULL;
		gchar* _tmp31_;
#line 180 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp29_ = key_file;
#line 180 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp30_ = g_key_file_get_string (_tmp29_, "Ask", "Icon", &_inner_error_);
#line 180 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp31_ = _tmp30_;
#line 180 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 951 "gnome-ask-password-agent.c"
			goto __catch3_g_error;
		}
#line 180 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (self->priv->icon);
#line 180 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		self->priv->icon = _tmp31_;
#line 958 "gnome-ask-password-agent.c"
	}
	goto __finally3;
	__catch3_g_error:
	{
		GError* e = NULL;
		gchar* _tmp32_;
#line 179 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		e = _inner_error_;
#line 179 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_inner_error_ = NULL;
#line 182 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp32_ = g_strdup ("dialog-password");
#line 182 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (self->priv->icon);
#line 182 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		self->priv->icon = _tmp32_;
#line 179 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_error_free0 (e);
#line 977 "gnome-ask-password-agent.c"
	}
	__finally3:
#line 179 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_inner_error_ != NULL) {
#line 179 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_propagate_error (error, _inner_error_);
#line 179 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_key_file_free0 (key_file);
#line 179 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return FALSE;
#line 988 "gnome-ask-password-agent.c"
	}
#line 184 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp33_ = self->priv->icon;
#line 184 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_status_icon_set_from_icon_name ((GtkStatusIcon*) self, _tmp33_);
#line 186 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_status_icon_set_visible ((GtkStatusIcon*) self, TRUE);
#line 188 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp34_ = gtk_status_icon_get_title ((GtkStatusIcon*) self);
#line 188 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp35_ = _tmp34_;
#line 188 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp36_ = self->priv->message;
#line 188 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp37_ = self->priv->icon;
#line 188 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp38_ = notify_notification_new (_tmp35_, _tmp36_, _tmp37_);
#line 188 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	n = _tmp38_;
#line 189 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp39_ = n;
#line 189 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	notify_notification_set_timeout (_tmp39_, 5000);
#line 190 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp40_ = n;
#line 190 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	notify_notification_show (_tmp40_, &_inner_error_);
#line 190 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_inner_error_ != NULL) {
#line 190 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_propagate_error (error, _inner_error_);
#line 190 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_object_unref0 (n);
#line 190 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_key_file_free0 (key_file);
#line 190 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return FALSE;
#line 1026 "gnome-ask-password-agent.c"
	}
#line 192 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	result = TRUE;
#line 192 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (n);
#line 192 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_key_file_free0 (key_file);
#line 192 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	return result;
#line 1036 "gnome-ask-password-agent.c"
}


static guint8* string_get_data (const gchar* self, int* result_length1) {
	guint8* result;
	guint8* res;
	gint res_length1;
	gint _res_size_;
	gint _tmp0_;
	gint _tmp1_;
	gint _tmp2_;
	guint8* _tmp3_;
	gint _tmp3__length1;
	guint8* _tmp4_;
	gint _tmp4__length1;
#line 1407 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, NULL);
#line 1408 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	res = (guint8*) self;
#line 1408 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	res_length1 = -1;
#line 1408 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	_res_size_ = res_length1;
#line 1409 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	_tmp0_ = strlen (self);
#line 1409 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	_tmp1_ = _tmp0_;
#line 1409 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	res_length1 = (gint) _tmp1_;
#line 1409 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	_tmp2_ = res_length1;
#line 1410 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	_tmp3_ = res;
#line 1410 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	_tmp3__length1 = res_length1;
#line 1410 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	_tmp4_ = _tmp3_;
#line 1410 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	_tmp4__length1 = _tmp3__length1;
#line 1410 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	if (result_length1) {
#line 1410 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
		*result_length1 = _tmp4__length1;
#line 1080 "gnome-ask-password-agent.c"
	}
#line 1410 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	result = _tmp4_;
#line 1410 "/usr/share/vala-0.16/vapi/glib-2.0.vapi"
	return result;
#line 1086 "gnome-ask-password-agent.c"
}


static void my_status_icon_status_icon_activate (MyStatusIcon* self) {
	GFile* _tmp0_;
	PasswordDialog* _tmp1_;
	const gchar* _tmp3_;
	const gchar* _tmp4_;
	PasswordDialog* _tmp5_;
	PasswordDialog* _tmp6_;
	PasswordDialog* _tmp7_;
	gint _tmp8_ = 0;
	gint _result_;
	PasswordDialog* _tmp9_;
	GtkEntry* _tmp10_;
	const gchar* _tmp11_ = NULL;
	gchar* _tmp12_;
	gchar* password;
	PasswordDialog* _tmp13_;
	gboolean _tmp14_ = FALSE;
	gint _tmp15_;
	gboolean _tmp17_;
	gint to_process = 0;
	GError * _inner_error_ = NULL;
#line 195 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_return_if_fail (self != NULL);
#line 197 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp0_ = self->priv->current;
#line 197 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp0_ == NULL) {
#line 198 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return;
#line 1119 "gnome-ask-password-agent.c"
	}
#line 200 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp1_ = self->priv->password_dialog;
#line 200 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp1_ != NULL) {
#line 1125 "gnome-ask-password-agent.c"
		PasswordDialog* _tmp2_;
#line 201 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp2_ = self->priv->password_dialog;
#line 201 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		gtk_window_present ((GtkWindow*) _tmp2_);
#line 202 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return;
#line 1133 "gnome-ask-password-agent.c"
	}
#line 205 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp3_ = self->priv->message;
#line 205 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp4_ = self->priv->icon;
#line 205 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp5_ = password_dialog_new (_tmp3_, _tmp4_);
#line 205 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp6_ = g_object_ref_sink (_tmp5_);
#line 205 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->priv->password_dialog);
#line 205 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self->priv->password_dialog = _tmp6_;
#line 207 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp7_ = self->priv->password_dialog;
#line 207 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp8_ = gtk_dialog_run ((GtkDialog*) _tmp7_);
#line 207 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_result_ = _tmp8_;
#line 208 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp9_ = self->priv->password_dialog;
#line 208 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp10_ = _tmp9_->entry;
#line 208 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp11_ = gtk_entry_get_text (_tmp10_);
#line 208 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp12_ = g_strdup (_tmp11_);
#line 208 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	password = _tmp12_;
#line 210 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp13_ = self->priv->password_dialog;
#line 210 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_object_destroy ((GtkObject*) _tmp13_);
#line 211 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->priv->password_dialog);
#line 211 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self->priv->password_dialog = NULL;
#line 213 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp15_ = _result_;
#line 213 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp15_ == ((gint) GTK_RESPONSE_REJECT)) {
#line 213 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp14_ = TRUE;
#line 1177 "gnome-ask-password-agent.c"
	} else {
		gint _tmp16_;
#line 214 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp16_ = _result_;
#line 214 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp14_ = _tmp16_ == ((gint) GTK_RESPONSE_DELETE_EVENT);
#line 1184 "gnome-ask-password-agent.c"
	}
#line 213 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp17_ = _tmp14_;
#line 213 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_tmp17_) {
#line 215 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (password);
#line 215 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return;
#line 1194 "gnome-ask-password-agent.c"
	}
	{
		const gchar* _tmp18_ = NULL;
		gint _tmp19_;
		gchar* _tmp20_;
		gchar* _tmp21_;
		const gchar* _tmp22_;
		gchar* _tmp23_;
		const gchar* _tmp24_;
		gchar* _tmp25_;
		gchar** _tmp26_ = NULL;
		gchar** _tmp27_;
		gint _tmp27__length1;
		gint _tmp28_ = 0;
		gint _tmp29_;
		GUnixOutputStream* _tmp30_;
		GOutputStream* stream;
		GOutputStream* _tmp31_;
		const gchar* _tmp32_;
		guint8* _tmp33_;
		gint _tmp33__length1;
		guint8* _tmp34_;
		gint _tmp34__length1;
#line 222 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp19_ = _result_;
#line 222 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_tmp19_ == ((gint) GTK_RESPONSE_OK)) {
#line 222 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp18_ = "1";
#line 1224 "gnome-ask-password-agent.c"
		} else {
#line 222 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_tmp18_ = "0";
#line 1228 "gnome-ask-password-agent.c"
		}
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp20_ = g_strdup ("/usr/bin/pkexec");
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp21_ = g_strdup ("/lib/systemd/systemd-reply-password");
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp22_ = _tmp18_;
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp23_ = g_strdup (_tmp22_);
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp24_ = self->priv->socket;
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp25_ = g_strdup (_tmp24_);
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp26_ = g_new0 (gchar*, 4 + 1);
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp26_[0] = _tmp20_;
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp26_[1] = _tmp21_;
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp26_[2] = _tmp23_;
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp26_[3] = _tmp25_;
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp27_ = _tmp26_;
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp27__length1 = 4;
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_spawn_async_with_pipes (NULL, _tmp27_, NULL, 0, NULL, NULL, NULL, &_tmp28_, NULL, NULL, &_inner_error_);
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		to_process = _tmp28_;
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp27_ = (_vala_array_free (_tmp27_, _tmp27__length1, (GDestroyNotify) g_free), NULL);
#line 220 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 1264 "gnome-ask-password-agent.c"
			goto __catch4_g_error;
		}
#line 231 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp29_ = to_process;
#line 231 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp30_ = (GUnixOutputStream*) g_unix_output_stream_new (_tmp29_, TRUE);
#line 231 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		stream = (GOutputStream*) _tmp30_;
#line 233 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp31_ = stream;
#line 233 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp32_ = password;
#line 233 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp33_ = string_get_data (_tmp32_, &_tmp33__length1);
#line 233 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp34_ = _tmp33_;
#line 233 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp34__length1 = _tmp33__length1;
#line 233 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_output_stream_write (_tmp31_, _tmp34_, (gsize) _tmp34__length1, NULL, &_inner_error_);
#line 233 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 233 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
			_g_object_unref0 (stream);
#line 1289 "gnome-ask-password-agent.c"
			goto __catch4_g_error;
		}
#line 219 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_object_unref0 (stream);
#line 1294 "gnome-ask-password-agent.c"
	}
	goto __finally4;
	__catch4_g_error:
	{
		GError* e = NULL;
		GError* _tmp35_;
		const gchar* _tmp36_;
#line 219 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		e = _inner_error_;
#line 219 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_inner_error_ = NULL;
#line 238 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp35_ = e;
#line 238 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp36_ = _tmp35_->message;
#line 238 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		show_error (_tmp36_);
#line 219 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_error_free0 (e);
#line 1314 "gnome-ask-password-agent.c"
	}
	__finally4:
#line 219 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_inner_error_ != NULL) {
#line 219 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_free0 (password);
#line 219 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.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 219 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_clear_error (&_inner_error_);
#line 219 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return;
#line 1327 "gnome-ask-password-agent.c"
	}
#line 195 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_free0 (password);
#line 1331 "gnome-ask-password-agent.c"
}


static void my_status_icon_class_init (MyStatusIconClass * klass) {
#line 73 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	my_status_icon_parent_class = g_type_class_peek_parent (klass);
#line 73 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_type_class_add_private (klass, sizeof (MyStatusIconPrivate));
#line 73 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	G_OBJECT_CLASS (klass)->finalize = my_status_icon_finalize;
#line 1342 "gnome-ask-password-agent.c"
}


static void my_status_icon_instance_init (MyStatusIcon * self) {
#line 73 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self->priv = MY_STATUS_ICON_GET_PRIVATE (self);
#line 1349 "gnome-ask-password-agent.c"
}


static void my_status_icon_finalize (GObject* obj) {
	MyStatusIcon * self;
#line 73 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	self = MY_STATUS_ICON (obj);
#line 75 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->priv->directory);
#line 76 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->priv->current);
#line 77 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->priv->file_monitor);
#line 79 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_free0 (self->priv->message);
#line 80 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_free0 (self->priv->icon);
#line 81 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_free0 (self->priv->socket);
#line 83 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (self->priv->password_dialog);
#line 73 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	G_OBJECT_CLASS (my_status_icon_parent_class)->finalize (obj);
#line 1373 "gnome-ask-password-agent.c"
}


GType my_status_icon_get_type (void) {
	static volatile gsize my_status_icon_type_id__volatile = 0;
	if (g_once_init_enter (&my_status_icon_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (MyStatusIconClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) my_status_icon_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (MyStatusIcon), 0, (GInstanceInitFunc) my_status_icon_instance_init, NULL };
		GType my_status_icon_type_id;
		my_status_icon_type_id = g_type_register_static (GTK_TYPE_STATUS_ICON, "MyStatusIcon", &g_define_type_info, 0);
		g_once_init_leave (&my_status_icon_type_id__volatile, my_status_icon_type_id);
	}
	return my_status_icon_type_id__volatile;
}


void show_error (const gchar* e) {
	const gchar* _tmp0_;
	GtkMessageDialog* _tmp1_;
	GtkMessageDialog* _tmp2_;
	GtkMessageDialog* m;
#line 247 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_return_if_fail (e != NULL);
#line 248 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp0_ = e;
#line 248 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp1_ = (GtkMessageDialog*) gtk_message_dialog_new (NULL, 0, GTK_MESSAGE_ERROR, GTK_BUTTONS_CLOSE, "%s", _tmp0_);
#line 248 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_tmp2_ = g_object_ref_sink (_tmp1_);
#line 248 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	m = _tmp2_;
#line 249 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_dialog_run ((GtkDialog*) m);
#line 250 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	gtk_object_destroy ((GtkObject*) m);
#line 247 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	_g_object_unref0 (m);
#line 1410 "gnome-ask-password-agent.c"
}


gint _vala_main (gchar** args, int args_length1) {
	gint result = 0;
	GError * _inner_error_ = NULL;
	{
		MyStatusIcon* _tmp0_;
		MyStatusIcon* i;
#line 255 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		gtk_init_with_args (&args_length1, &args, "[OPTION...]", entries, "systemd-ask-password-agent", &_inner_error_);
#line 255 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 1424 "gnome-ask-password-agent.c"
			goto __catch5_g_error;
		}
#line 256 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		notify_init ("Password Agent");
#line 258 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp0_ = my_status_icon_new (&_inner_error_);
#line 258 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		i = _tmp0_;
#line 258 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		if (_inner_error_ != NULL) {
#line 1435 "gnome-ask-password-agent.c"
			goto __catch5_g_error;
		}
#line 259 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		gtk_main ();
#line 254 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_object_unref0 (i);
#line 1442 "gnome-ask-password-agent.c"
	}
	goto __finally5;
	__catch5_g_error:
	{
		GError* e = NULL;
		GError* _tmp1_;
		const gchar* _tmp2_;
#line 254 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		e = _inner_error_;
#line 254 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_inner_error_ = NULL;
#line 262 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp1_ = e;
#line 262 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_tmp2_ = _tmp1_->message;
#line 262 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		show_error (_tmp2_);
#line 254 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		_g_error_free0 (e);
#line 1462 "gnome-ask-password-agent.c"
	}
	__finally5:
#line 254 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	if (_inner_error_ != NULL) {
#line 254 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.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 254 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		g_clear_error (&_inner_error_);
#line 254 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
		return 0;
#line 1473 "gnome-ask-password-agent.c"
	}
#line 265 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	result = 0;
#line 265 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	return result;
#line 1479 "gnome-ask-password-agent.c"
}


int main (int argc, char ** argv) {
#line 253 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	g_type_init ();
#line 253 "/home/lennart/projects/systemd/src/gnome-ask-password-agent.vala"
	return _vala_main (argv, argc);
#line 1488 "gnome-ask-password-agent.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);
}



