rpms/gparted/EL-5 gparted-realpath-fix.patch, NONE, 1.1 gparted-refresh_crash-fix.patch, NONE, 1.1 gparted.spec, 1.19, 1.20

Deji Akingunola (deji) fedora-extras-commits at redhat.com
Mon Dec 17 01:24:10 UTC 2007


Author: deji

Update of /cvs/extras/rpms/gparted/EL-5
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv12389

Modified Files:
	gparted.spec 
Added Files:
	gparted-realpath-fix.patch gparted-refresh_crash-fix.patch 
Log Message:
* Sun Dec 16 2007 Deji Akingunola <dakingun at gmail.com> - 0.3.3-4
- Branch off for EL-5
- Apply a couple of patches from F-7 branch
- Remove the X-Fedora category form the desktop file


gparted-realpath-fix.patch:

--- NEW FILE gparted-realpath-fix.patch ---
--- src/GParted_Core.cc	2006-12-05 14:39:31.000000000 -0500
+++ src/GParted_Core.cc.new	2007-11-22 00:01:43.000000000 -0500
@@ -487,19 +487,23 @@
 		while ( getline( proc_partitions, line ) )
 			if ( sscanf( line .c_str(), "%*d %*d %*d %255s", c_str ) == 1 )
 			{
+				char *real_path = NULL;
+
 				line = "/dev/" ; 
 				line += c_str ;
 				
 				//FIXME: it seems realpath is very unsafe to use (manpage)...
+				real_path = realpath( line .c_str(), NULL ) ;
 				if ( file_test( line, Glib::FILE_TEST_EXISTS ) &&
-				     realpath( line .c_str(), c_str ) &&
+				     real_path &&
 				     line != c_str )
 				{
 					//because we can make no assumption about which path libparted will detect
 					//we add all combinations.
 					alternate_paths[ c_str ] = line ;
-					alternate_paths[ line ] = c_str ;
 				}
+				if ( real_path )
+				  free( real_path ) ;
 			}
 
 		proc_partitions .close() ;

gparted-refresh_crash-fix.patch:

--- NEW FILE gparted-refresh_crash-fix.patch ---
--- include/Win_GParted.h	2006-11-25 09:56:30.000000000 -0500
+++ include/Win_GParted.h.new	2007-10-30 00:37:29.000000000 -0400
@@ -233,6 +233,7 @@
 	unsigned short new_count;//new_count keeps track of the new created partitions
 	FS fs ;
 	bool OPERATIONSLIST_OPEN ;
+	sigc::connection combo_devices_signal_changed_id ;
 									
 	GParted_Core gparted_core ;
 	std::vector<Gtk::Label *> device_info ;
--- src/Win_GParted.cc	2006-12-01 08:14:23.000000000 -0500
+++ src/Win_GParted.cc.new	2007-10-30 00:35:47.000000000 -0400
@@ -260,7 +260,8 @@
 	combo_devices .pack_start( treeview_devices_columns .device ) ;
 	combo_devices .pack_start( treeview_devices_columns .size, false ) ;
 	
-	combo_devices .signal_changed() .connect( sigc::mem_fun(*this, &Win_GParted::combo_devices_changed) );
+	combo_devices_signal_changed_id =
+		combo_devices .signal_changed() .connect( sigc::mem_fun(*this, &Win_GParted::combo_devices_changed) );
 
 	hbox_toolbar .pack_start( combo_devices, Gtk::PACK_SHRINK ) ;
 }
@@ -502,6 +503,7 @@
 
 void Win_GParted::refresh_combo_devices()
 {
+	combo_devices_signal_changed_id .block() ;
 	liststore_devices ->clear() ;
 	
 	menu = manage( new Gtk::Menu() ) ;
@@ -538,6 +540,7 @@
 		menubar_main .items()[ 0 ] .get_submenu() ->items()[ 1 ] .set_submenu( *menu ) ;
 	}
 	
+	combo_devices_signal_changed_id .unblock() ;
 	combo_devices .set_active( current_device ) ;
 }
 


Index: gparted.spec
===================================================================
RCS file: /cvs/extras/rpms/gparted/EL-5/gparted.spec,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- gparted.spec	14 Jun 2007 22:07:43 -0000	1.19
+++ gparted.spec	17 Dec 2007 01:23:36 -0000	1.20
@@ -1,12 +1,14 @@
 Summary: Gnome Partition Editor
 Name:    gparted
 Version: 0.3.3
-Release: 3%{?dist}
+Release: 4%{?dist}
 Group:   Applications/System
 License: GPL
 URL:     http://gparted.sourceforge.net
 Source0: http://dl.sf.net/sourceforge/%{name}/%{name}-%{version}.tar.bz2
-Patch0: gparted-devices.patch
+Patch0:	 gparted-devices.patch
+Patch1:	 gparted-realpath-fix.patch
+Patch2:	 gparted-refresh_crash-fix.patch
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires: gtkmm24-devel parted-devel 
 BuildRequires: e2fsprogs-devel gettext perl(XML::Parser) 
@@ -22,6 +24,8 @@
 %prep
 %setup -q
 %patch0 -p0 -b .devs
+%patch1 -p0 -b .realpath
+%patch2 -p0 -b .refresh
 
 %build
 %configure
@@ -35,7 +39,6 @@
         --vendor fedora                                  \
         --dir %{buildroot}%{_datadir}/applications       \
 	--mode 0644				         \
-        --add-category X-Fedora                          \
         %{buildroot}%{_datadir}/applications/%{name}.desktop
 
 #### consolehelper stuff (stolen from extras' synaptic)
@@ -79,6 +82,11 @@
 %config(noreplace) %{_sysconfdir}/security/console.apps/gparted
 
 %changelog
+* Sun Dec 16 2007 Deji Akingunola <dakingun at gmail.com> - 0.3.3-4
+- Branch off for EL-5
+- Apply a couple of patches from F-7 branch
+- Remove the X-Fedora category form the desktop file
+
 * Mon Jun 11 2007 Deji Akingunola <dakingun at gmail.com> - 0.3.3-3
 - Apply patch to only detect real devices, useful for correcting gparted slow 
  startup in situations when floppy drives doesn't exist but are enabled in bios




More information about the fedora-extras-commits mailing list