[Gpa-commits] r763 - trunk/src

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Thu Nov 30 19:16:15 CET 2006


Author: marcus
Date: 2006-11-30 19:16:15 +0100 (Thu, 30 Nov 2006)
New Revision: 763

Modified:
   trunk/src/ChangeLog
   trunk/src/passwddlg.c
Log:
2006-11-30  Marcus Brinkmann  <marcus at g10code.de>

	* passwddlg.c (gpa_change_passphrase_dialog_run): Initialize
	PASSWD.  Release PASSWD if set before overwriting it.


Modified: trunk/src/ChangeLog
===================================================================
--- trunk/src/ChangeLog	2006-07-25 07:15:03 UTC (rev 762)
+++ trunk/src/ChangeLog	2006-11-30 18:16:15 UTC (rev 763)
@@ -1,3 +1,8 @@
+2006-11-30  Marcus Brinkmann  <marcus at g10code.de>
+
+	* passwddlg.c (gpa_change_passphrase_dialog_run): Initialize
+	PASSWD.  Release PASSWD if set before overwriting it.
+
 2006-07-15  Marcus Brinkmann  <marcus at g10code.de>
 
 	* gpa.rc: Move to ...

Modified: trunk/src/passwddlg.c
===================================================================
--- trunk/src/passwddlg.c	2006-07-25 07:15:03 UTC (rev 762)
+++ trunk/src/passwddlg.c	2006-11-30 18:16:15 UTC (rev 763)
@@ -88,7 +88,7 @@
   GtkWidget *table;
   GtkWidget *label, *entry, *passwd_entry, *repeat_entry;
   GtkResponseType response;
-  gchar *passwd;
+  gchar *passwd = NULL;
   const gchar *repeat;
 
   dialog = gtk_dialog_new_with_buttons (_("Choose new passphrase"), NULL,
@@ -135,6 +135,8 @@
       gtk_widget_grab_focus (passwd_entry);
       gtk_widget_show_all (dialog);
       response = gtk_dialog_run (GTK_DIALOG (dialog));
+      if (passwd)
+	g_free (passwd);
       passwd = g_strdup (gtk_entry_get_text (GTK_ENTRY (passwd_entry)));
       repeat = gtk_entry_get_text (GTK_ENTRY (repeat_entry));
     } 



More information about the Gpa-commits mailing list