$OpenBSD: patch-capplets_about-me_gnome-about-me_c,v 1.4 2009/10/13 19:09:05 ajacoutot Exp $

Spawn a gnome-terminal to allow users to change their passwords, as we cannot
fork passwd(1) to the background.
From Open Solaris' control-center-01-passwd-in-terminal.diff

--- capplets/about-me/gnome-about-me.c.orig	Mon Aug 17 10:40:16 2009
+++ capplets/about-me/gnome-about-me.c	Tue Oct 13 19:25:22 2009
@@ -820,7 +820,25 @@ about_me_passwd_clicked_cb (GtkWidget *button, GnomeAb
 	GtkBuilder *dialog;
 
 	dialog = me->dialog;
+#if defined __OpenBSD__
+    /* Use gnome-terminal embedded passwd due to inability to fork passwd in
+     * the background.
+     */
+    {
+        GError  *error = NULL;
+        gchar   *command = NULL;
+
+        command = g_strdup_printf("gnome-terminal --window --title '%s' --hide-menubar -e /usr/bin/passwd",
+                                _("Change password") );
+
+        if ( command != NULL ) {
+            g_spawn_command_line_async( command, &error);
+            g_free(command);
+        }
+    }
+#else
 	gnome_about_me_password (GTK_WINDOW (WID ("about-me-dialog")));
+#endif
 }
 
 static void
