rpms/mdadm/F-7 mdadm-2.6.2-file-leak.patch, 1.1, 1.2 mdadm.spec, 1.44, 1.45 mdmonitor.init, 1.6, 1.7

Doug Ledford (dledford) fedora-extras-commits at redhat.com
Fri Jul 6 16:58:49 UTC 2007


Author: dledford

Update of /cvs/extras/rpms/mdadm/F-7
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv15658

Modified Files:
	mdadm-2.6.2-file-leak.patch mdadm.spec mdmonitor.init 
Log Message:
* Fri Jul 06 2007 Doug Ledford <dledford at redhat.com> - 2.6.2-3
- Oops, had to update the file leak patch, missed one thing
- Minor tweak to return codes in init script and add LSB header
- Resolves: bz244582, bz246980


mdadm-2.6.2-file-leak.patch:

Index: mdadm-2.6.2-file-leak.patch
===================================================================
RCS file: /cvs/extras/rpms/mdadm/F-7/mdadm-2.6.2-file-leak.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- mdadm-2.6.2-file-leak.patch	3 Jul 2007 20:40:37 -0000	1.1
+++ mdadm-2.6.2-file-leak.patch	6 Jul 2007 16:58:43 -0000	1.2
@@ -1,5 +1,15 @@
---- mdadm-2.6.2/mdstat.c.fileleak	2007-07-02 12:25:01.000000000 -0400
-+++ mdadm-2.6.2/mdstat.c	2007-07-02 12:25:04.000000000 -0400
+--- mdadm-2.6.2/Monitor.c.leak	2007-07-06 12:20:05.000000000 -0400
++++ mdadm-2.6.2/Monitor.c	2007-07-06 12:21:44.000000000 -0400
+@@ -234,6 +234,7 @@ int Monitor(mddev_dev_t devlist,
+ */				st->err=1;
+ 				continue;
+ 			}
++			fcntl(fd, F_SETFD, FD_CLOEXEC);
+ 			if (ioctl(fd, GET_ARRAY_INFO, &array)<0) {
+ 				if (!st->err)
+ 					alert("DeviceDisappeared", dev, NULL,
+--- mdadm-2.6.2/mdstat.c.leak	2006-12-18 21:35:17.000000000 -0500
++++ mdadm-2.6.2/mdstat.c	2007-07-06 12:19:55.000000000 -0400
 @@ -114,6 +114,8 @@ struct mdstat_ent *mdstat_read(int hold,
  		f = fopen("/proc/mdstat", "r");
  	if (f == NULL)


Index: mdadm.spec
===================================================================
RCS file: /cvs/extras/rpms/mdadm/F-7/mdadm.spec,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -r1.44 -r1.45
--- mdadm.spec	3 Jul 2007 20:40:37 -0000	1.44
+++ mdadm.spec	6 Jul 2007 16:58:43 -0000	1.45
@@ -1,7 +1,7 @@
 Summary:     The mdadm program controls Linux md devices (software RAID arrays)
 Name:        mdadm
 Version:     2.6.2
-Release:     2%{?dist}
+Release:     3%{?dist}
 Source:      http://www.cse.unsw.edu.au/~neilb/source/mdadm/mdadm-%{version}.tgz
 Source1:     mdmonitor.init
 Patch1:      mdadm-2.5.2-s390-build.patch
@@ -89,6 +89,11 @@
 %attr(0700,root,root) %dir /var/run/mdadm
 
 %changelog
+* Fri Jul 06 2007 Doug Ledford <dledford at redhat.com> - 2.6.2-3
+- Oops, had to update the file leak patch, missed one thing
+- Minor tweak to return codes in init script and add LSB header
+- Resolves: bz244582, bz246980
+
 * Mon Jul 02 2007 Doug Ledford <dledford at redhat.com> - 2.6.2-2
 - Fix a file leak issue when mdadm is in monitor mode
 - Update mdadm init script so that status will always run and so


Index: mdmonitor.init
===================================================================
RCS file: /cvs/extras/rpms/mdadm/F-7/mdmonitor.init,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- mdmonitor.init	3 Jul 2007 20:40:37 -0000	1.6
+++ mdmonitor.init	6 Jul 2007 16:58:43 -0000	1.7
@@ -7,8 +7,18 @@
 # description: software RAID monitoring and management
 # config: /etc/mdadm.conf
 #
-
 # Copyright 2002 Red Hat, Inc.
+#
+### BEGIN INIT INFO
+# Default-Start: 2 3 4 5
+# Default-Stop: 0 1 6
+# Short-Description: Start and stop the MD software RAID monitor
+# Description: The mdmonitor service checks the status of all software
+#	RAID arrays on the system.  In the event that any of the arrays
+#	transition into a degraded state, it notifies the system
+#	administrator.  Other options are available, see the mdadm.conf
+#	and mdadm man pages for possible ways to configure this service.
+### END INIT INFO
 
 PIDFILE=/var/run/mdadm/mdadm.pid
 PATH=/sbin:/usr/sbin:$PATH
@@ -23,7 +33,7 @@
 
 usage ()
 {
-    echo "Usage: service $prog {start|stop|status|restart|condrestart}"
+    echo "Usage: service $prog {start|stop|status|restart|try-restart|force-reload}"
     RETVAL=1
 }
 
@@ -47,7 +57,7 @@
 
 stop ()
 {
-    [ -f /var/lock/subsys/$prog ] || return 7
+    [ -f /var/lock/subsys/$prog ] || return 0
     echo -n "Killing $prog: "
     killproc mdadm
     echo
@@ -73,6 +83,8 @@
     restart) restart; RETVAL=$? ;;
     reload) RETVAL=3 ;;
     condrestart) condrestart; RETVAL=$? ;;
+    try-restart) condrestart; RETVAL=$? ;;
+    force-reload) condrestart; RETVAL=$? ;;
     *) usage ; RETVAL=2 ;;
 esac
 




More information about the scm-commits mailing list