rpms/xfburn/F-12 xfburn-0.4.2-fix-crash-on-iso-burning.patch, NONE, 1.1 xfburn-0.4.2-mark-constructor-properties-make-some-constructor_o.patch, NONE, 1.1 xfburn.spec, 1.6, 1.7

Christoph Wickert cwickert at fedoraproject.org
Thu Oct 29 23:33:37 UTC 2009


Author: cwickert

Update of /cvs/pkgs/rpms/xfburn/F-12
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv28657/F-12

Modified Files:
	xfburn.spec 
Added Files:
	xfburn-0.4.2-fix-crash-on-iso-burning.patch 
	xfburn-0.4.2-mark-constructor-properties-make-some-constructor_o.patch 
Log Message:
* Thu Oct 30 2009 Christoph Wickert <cwickert at fedoraproject.org> - 0.4.2-2
- Fix infinite loop in blank disk dialog (#525515)
- Don't crash on burning ISO image (#525518)


xfburn-0.4.2-fix-crash-on-iso-burning.patch:
 xfburn-burn-image-dialog.c |   29 +++++++++++++++++++++++------
 1 file changed, 23 insertions(+), 6 deletions(-)

--- NEW FILE xfburn-0.4.2-fix-crash-on-iso-burning.patch ---
diff -dur xfburn-0.4.2.orig/xfburn/xfburn-burn-image-dialog.c xfburn-0.4.2/xfburn/xfburn-burn-image-dialog.c
--- xfburn-0.4.2.orig/xfburn/xfburn-burn-image-dialog.c	2009-07-13 05:24:06.000000000 +0200
+++ xfburn-0.4.2/xfburn/xfburn-burn-image-dialog.c	2009-10-29 23:27:12.000000000 +0100
@@ -66,12 +66,16 @@
 
   GtkWidget *burn_button;
 
+  XfburnDeviceList *devlist;
+  gulong handler_volchange;
+
   ThreadBurnIsoParams *params;
 } XfburnBurnImageDialogPrivate;
 
 /* prototypes */
 static void xfburn_burn_image_dialog_class_init (XfburnBurnImageDialogClass * klass);
 static void xfburn_burn_image_dialog_init (XfburnBurnImageDialog * sp);
+static void xfburn_burn_image_dialog_finalize (GObject *object);
 
 void burn_image_dialog_error (XfburnBurnImageDialog * dialog, const gchar * msg_error);
 static void cb_volume_change_end (XfburnDeviceList *devlist, gboolean device_changed, XfburnDevice *device, XfburnBurnImageDialog * dialog);
@@ -115,8 +119,13 @@
 static void
 xfburn_burn_image_dialog_class_init (XfburnBurnImageDialogClass * klass)
 {
+  GObjectClass *object_class = G_OBJECT_CLASS (klass);
+
   g_type_class_add_private (klass, sizeof (XfburnBurnImageDialogPrivate));
+
   parent_class = g_type_class_peek_parent (klass);
+
+  object_class->finalize     = xfburn_burn_image_dialog_finalize;
 }
 
 static void
@@ -130,7 +139,6 @@
   GtkWidget *frame;
   GtkWidget *vbox;
   GtkWidget *button;
-  XfburnDeviceList *devlist;
   XfburnDevice *device;
 
   gtk_window_set_title (GTK_WINDOW (obj), _("Burn image"));
@@ -208,19 +216,28 @@
   gtk_widget_grab_focus (priv->burn_button);
   gtk_widget_grab_default (priv->burn_button);
 
-  devlist = xfburn_device_list_new ();
+  priv->devlist = xfburn_device_list_new ();
 
-  g_signal_connect (G_OBJECT (devlist), "volume-change-end", G_CALLBACK (cb_volume_change_end), obj);
+  priv->handler_volchange = g_signal_connect (G_OBJECT (priv->devlist), "volume-change-end", G_CALLBACK (cb_volume_change_end), obj);
   g_signal_connect (G_OBJECT (obj), "response", G_CALLBACK (cb_dialog_response), obj);
-  device = xfburn_device_list_get_current_device (devlist);
+  device = xfburn_device_list_get_current_device (priv->devlist);
 
-  cb_volume_change_end (devlist, TRUE, device, obj);
+  cb_volume_change_end (priv->devlist, TRUE, device, obj);
 
   if (device)
     gtk_widget_set_sensitive (priv->check_dummy, xfburn_device_can_dummy_write (device));
+}
 
-  g_object_unref (G_OBJECT (devlist));
+static void
+xfburn_burn_image_dialog_finalize (GObject *object)
+{
+  XfburnBurnImageDialog *dialog = XFBURN_BURN_IMAGE_DIALOG (object);
+  XfburnBurnImageDialogPrivate *priv = XFBURN_BURN_IMAGE_DIALOG_GET_PRIVATE (dialog);
 
+  g_signal_handler_disconnect (priv->devlist, priv->handler_volchange);
+  g_object_unref (priv->devlist);
+
+  G_OBJECT_CLASS (parent_class)->finalize (object);
 }
 
 /*************/

xfburn-0.4.2-mark-constructor-properties-make-some-constructor_o.patch:
 xfburn-device-box.c  |   40 ++++++++++++++++++++++------------------
 xfburn-device-list.c |    1 +
 2 files changed, 23 insertions(+), 18 deletions(-)

--- NEW FILE xfburn-0.4.2-mark-constructor-properties-make-some-constructor_o.patch ---
diff -dur xfburn-0.4.2.orig/xfburn/xfburn-device-box.c xfburn-0.4.2/xfburn/xfburn-device-box.c
--- xfburn-0.4.2.orig/xfburn/xfburn-device-box.c	2009-07-13 05:24:06.000000000 +0200
+++ xfburn-0.4.2/xfburn/xfburn-device-box.c	2009-10-30 00:03:24.000000000 +0100
@@ -1,6 +1,7 @@
 /* $Id: xfburn-device-box.c 7718 2009-07-13 03:24:04Z squisher $ */
 /*
  * Copyright (c) 2006 Jean-François Wauthy (pollux at xfce.org)
+ * Copyright (c) 2008-2009 David Mohr <david at mcbf.net>
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -104,7 +105,7 @@
 static void xfburn_device_box_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec);
 static void xfburn_device_box_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec);
 
-static guint ask_for_blanking (XfburnDeviceBoxPrivate *priv);
+static gboolean ask_for_blanking (XfburnDeviceBoxPrivate *priv);
 static void status_label_update (XfburnDeviceBoxPrivate *priv);
 static gboolean check_disc_validity (XfburnDeviceBoxPrivate *priv);
 static void refresh_drive_info (XfburnDeviceBox *box, XfburnDevice *device);
@@ -171,15 +172,16 @@
     
   g_object_class_install_property (object_class, PROP_SHOW_WRITERS_ONLY, 
                                    g_param_spec_boolean ("show-writers-only", _("Show writers only"),
-                                                        _("Show writers only"), FALSE, G_PARAM_READWRITE));
+                                                        _("Show writers only"),
+                                                        FALSE, G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
   g_object_class_install_property (object_class, PROP_SHOW_SPEED_SELECTION, 
                                    g_param_spec_boolean ("show-speed-selection", _("Show speed selection"),
                                                         _("Show speed selection combo"), 
-                                                        FALSE, G_PARAM_READWRITE));
+                                                        FALSE, G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
   g_object_class_install_property (object_class, PROP_SHOW_MODE_SELECTION, 
                                    g_param_spec_boolean ("show-mode-selection", _("Show mode selection"),
                                                         _("Show mode selection combo"), 
-                                                        FALSE, G_PARAM_READWRITE));
+                                                        FALSE, G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
   g_object_class_install_property (object_class, PROP_VALID, 
                                    g_param_spec_boolean ("valid", _("Is it a valid combination"),
                                                         _("Is the combination of hardware and disc valid to burn the composition?"), 
@@ -187,11 +189,11 @@
   g_object_class_install_property (object_class, PROP_BLANK_MODE, 
                                    g_param_spec_boolean ("blank-mode", _("Blank mode"),
                                                         _("The blank mode shows different disc status messages than regular mode"), 
-                                                        FALSE, G_PARAM_READWRITE));
+                                                        FALSE, G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
   g_object_class_install_property (object_class, PROP_ACCEPT_ONLY_CD, 
                                    g_param_spec_boolean ("accept-only-cd", _("Accept only CDs as valid discs"),
                                                         _("Accept only CDs as valid discs"), 
-                                                        FALSE, G_PARAM_READWRITE));
+                                                        FALSE, G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
 }
 
 static GObject * 
@@ -256,6 +258,10 @@
   gtk_cell_layout_set_attributes (GTK_CELL_LAYOUT (priv->combo_speed), cell, "text", SPEED_TEXT_COLUMN, NULL);
   gtk_widget_show (priv->combo_speed);
   gtk_box_pack_start (GTK_BOX (priv->hbox_speed_selection), priv->combo_speed, TRUE, TRUE, BORDER);
+  if (priv->show_speed_selection) {
+    gtk_widget_show (priv->hbox_speed_selection);
+    fill_combo_speed (XFBURN_DEVICE_BOX (box), xfburn_device_list_get_current_device (devlist));
+  }
 
   /* mode */
   priv->hbox_mode_selection = gtk_hbox_new (FALSE, 0);
@@ -278,6 +284,11 @@
   g_object_get (G_OBJECT (devlist), "num-burners", &n_burners, NULL);
   gtk_widget_set_sensitive (priv->combo_mode, n_burners > 0);
 
+  if (priv->show_mode_selection) {
+    gtk_widget_show (priv->hbox_mode_selection);
+    fill_combo_mode (XFBURN_DEVICE_BOX (box), xfburn_device_list_get_current_device (devlist));
+  }
+
   /* status label */
   priv->status_label = gtk_label_new ("");
   priv->status_text = "";
@@ -345,19 +356,9 @@
       break;
     case PROP_SHOW_SPEED_SELECTION:
       priv->show_speed_selection = g_value_get_boolean (value);
-      if (priv->show_speed_selection) {
-        gtk_widget_show (priv->hbox_speed_selection);
-        fill_combo_speed (XFBURN_DEVICE_BOX (object), xfburn_device_list_get_current_device (priv->devlist));
-      } else
-        gtk_widget_hide (priv->hbox_speed_selection);
       break;
     case PROP_SHOW_MODE_SELECTION:
       priv->show_mode_selection = g_value_get_boolean (value);
-      if (priv->show_mode_selection) {
-        gtk_widget_show (priv->hbox_mode_selection);
-        fill_combo_mode (XFBURN_DEVICE_BOX (object), xfburn_device_list_get_current_device (priv->devlist));
-      } else
-        gtk_widget_hide (priv->hbox_mode_selection);
       break;
     case PROP_BLANK_MODE:
       priv->blank_mode = g_value_get_boolean (value);
@@ -503,7 +504,7 @@
   g_free (text);
 }
 
-static guint
+static gboolean
 ask_for_blanking (XfburnDeviceBoxPrivate *priv)
 {
   gboolean do_blank;
@@ -511,8 +512,9 @@
   if (priv->have_asked_for_blanking)
     return FALSE;
 
-  gdk_threads_enter ();
   priv->have_asked_for_blanking = TRUE;
+
+  gdk_threads_enter ();
   do_blank = xfburn_ask_yes_no (GTK_MESSAGE_QUESTION, "A full, but erasable disc is in the drive",
                                          "Do you want to blank the disc, so that it can be used for the upcoming burn process?");
 
@@ -544,6 +546,8 @@
   gtk_label_set_text (GTK_LABEL (priv->disc_label), profile_name);
   g_free (profile_name);
 
+  DBG ("blank_mode = %d", priv->blank_mode);
+
   if (!priv->blank_mode) {
     /* for burning */
     switch (profile_no) {
Nur in xfburn-0.4.2/xfburn: xfburn-device-box.c.orig.
diff -dur xfburn-0.4.2.orig/xfburn/xfburn-device-list.c xfburn-0.4.2/xfburn/xfburn-device-list.c
--- xfburn-0.4.2.orig/xfburn/xfburn-device-list.c	2009-07-13 05:24:06.000000000 +0200
+++ xfburn-0.4.2/xfburn/xfburn-device-list.c	2009-10-30 00:03:24.000000000 +0100
@@ -1,6 +1,7 @@
 /* $Id: xfburn-device-list.c 7718 2009-07-13 03:24:04Z squisher $ */
 /*
  * Copyright (c) 2005-2006 Jean-François Wauthy (pollux at xfce.org)
+ * Copyright (c) 2008-2009 David Mohr <david at mcbf.net>
  *
  *  This program is free software; you can redistribute it and/or modify
  *  it under the terms of the GNU General Public License as published by
Nur in xfburn-0.4.2/xfburn: xfburn-device-list.c.orig.


Index: xfburn.spec
===================================================================
RCS file: /cvs/pkgs/rpms/xfburn/F-12/xfburn.spec,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -p -r1.6 -r1.7
--- xfburn.spec	24 Jul 2009 16:21:21 -0000	1.6
+++ xfburn.spec	29 Oct 2009 23:33:35 -0000	1.7
@@ -1,12 +1,19 @@
 Name:           xfburn
 Version:        0.4.2
-Release:        1%{?dist}
+Release:        2%{?dist}
 Summary:        Simple CD burning tool for Xfce
 
 Group:          Applications/Archiving
 License:        GPLv2+
 URL:            http://goodies.xfce.org/projects/applications/%{name}
 Source0:        http://www.xfce.org/archive/src/apps/xfburn/0.4/%{name}-%{version}.tar.bz2
+# fix for https://bugzilla.redhat.com/show_bug.cgi?id=525515
+# http://git.xfce.org/apps/xfburn/commit/?id=78995b7eee0acde27bd0ea41137a7635174d362e
+Patch0:         xfburn-0.4.2-mark-constructor-properties-make-some-constructor_o.patch
+# fix for https://bugzilla.redhat.com/show_bug.cgi?id=525518
+# created from several upstream commits as described in
+# http://bugzilla.xfce.org/show_bug.cgi?id=5678#c23
+Patch1:         xfburn-0.4.2-fix-crash-on-iso-burning.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:  libxfcegui4-devel >= 4.4.0 Thunar-devel >= 0.3.0 
@@ -24,6 +31,8 @@ compositions of data to either CD or DVD
 
 %prep
 %setup -q
+%patch0 -p1 -b .mark-constructor-properties
+%patch1 -p1 -b .crash-on-iso-burning
 
 
 %build
@@ -44,20 +53,21 @@ desktop-file-install --vendor ""        
 
 %post
 update-desktop-database &> /dev/null ||:
-touch --no-create %{_datadir}/icons/hicolor
-if [ -x %{_bindir}/gtk-update-icon-cache ]; then
-  %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
-fi
+touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
 
 
 %postun
 update-desktop-database &> /dev/null ||:
-touch --no-create %{_datadir}/icons/hicolor
-if [ -x %{_bindir}/gtk-update-icon-cache ]; then
-  %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
+if [ $1 -eq 0 ] ; then
+    touch --no-create %{_datadir}/icons/hicolor &>/dev/null
+    gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
 fi
 
 
+%posttrans
+gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -76,6 +86,10 @@ rm -rf $RPM_BUILD_ROOT
 
 
 %changelog
+* Thu Oct 30 2009 Christoph Wickert <cwickert at fedoraproject.org> - 0.4.2-2
+- Fix infinite loop in blank disk dialog (#525515)
+- Don't crash on burning ISO image (#525518)
+
 * Fri Jul 24 2009 Christoph Wickert <cwickert at fedoraproject.org> - 0.4.2-1
 - Update to 0.4.2
 




More information about the fedora-extras-commits mailing list