From 4fe36b2a5e29004a88f1d2a0a6466106ad2b45d5 Mon Sep 17 00:00:00 2001 From: Fernando Herrera Date: Tue, 28 Aug 2007 00:37:45 +0000 Subject: [PATCH] Don't free desktop path. Translate program description correctly, patch by 2007-08-28 Fernando Herrera * src/bug-buddy.c: (on_save_clicked), (main): Don't free desktop path. Translate program description correctly, patch by Gabor Kelemen, fix bug #450144 svn path=/trunk/; revision=2358 --- ChangeLog | 6 ++++++ src/bug-buddy.c | 9 +++++---- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index c73b5b2e..a862f3ee 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2007-08-28 Fernando Herrera + * src/bug-buddy.c: (on_save_clicked), (main): Don't free desktop path. + Translate program description correctly, patch by Gabor Kelemen, fix + bug #450144 + +2007-08-28 Fernando Herrera + * src/bug-buddy.c: (on_save_clicked): Use special dir functions to get homedir. Patch by Luca Ferretti. Fix bug #453115 diff --git a/src/bug-buddy.c b/src/bug-buddy.c index 0aa19510..12e5ae10 100644 --- a/src/bug-buddy.c +++ b/src/bug-buddy.c @@ -1153,7 +1153,7 @@ on_save_clicked (GtkWidget *button, gpointer user_data) { GtkBuilder *ui = (GtkBuilder *)user_data; GtkWidget *dialog; - char *desktop; + const char *desktop; char *filename; gboolean desktop_is_home_dir, saved; GConfClient *gconf_client; @@ -1174,7 +1174,7 @@ on_save_clicked (GtkWidget *button, gpointer user_data) g_object_unref (gconf_client); if (desktop_is_home_dir) - desktop = g_strdup (g_get_home_dir()); + desktop = g_get_home_dir(); else desktop = g_get_user_special_dir (G_USER_DIRECTORY_DESKTOP); @@ -1182,7 +1182,6 @@ on_save_clicked (GtkWidget *button, gpointer user_data) filename = g_strconcat (gopt_data.app_file, _("-bugreport.txt"), NULL); gtk_file_chooser_set_current_name (GTK_FILE_CHOOSER (dialog), filename); - g_free (desktop); g_free (filename); if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_ACCEPT) { @@ -1677,9 +1676,11 @@ main (int argc, char *argv[]) bind_textdomain_codeset (PACKAGE, "UTF-8"); textdomain (PACKAGE); - context = g_option_context_new (_("\n\nBug Buddy is a utility that helps report debugging\n" + context = g_option_context_new (N_("\n\nBug Buddy is a utility that helps report debugging\n" "information to the GNOME Bugzilla when a program crashes.")); + g_option_context_set_translation_domain (context, GETTEXT_PACKAGE); + g_option_context_add_main_entries (context, options, GETTEXT_PACKAGE); program = gnome_program_init (PACKAGE, VERSION, -- 2.11.4.GIT