rpms/smartmontools/FC-6 smartmontools-5.37-cloexec.patch, NONE, 1.1 .cvsignore, 1.4, 1.5 smartd.initd, 1.4, 1.5 smartmontools.spec, 1.24, 1.25 sources, 1.3, 1.4

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Wed Apr 25 12:58:37 UTC 2007


Author: tsmetana

Update of /cvs/dist/rpms/smartmontools/FC-6
In directory cvs.devel.redhat.com:/tmp/cvs-serv24886

Modified Files:
	.cvsignore smartd.initd smartmontools.spec sources 
Added Files:
	smartmontools-5.37-cloexec.patch 
Log Message:
New upstream version (#237399), fix minor bug (#237531)

smartmontools-5.37-cloexec.patch:
 os_linux.cpp |   16 ++++++++++------
 1 files changed, 10 insertions(+), 6 deletions(-)

--- NEW FILE smartmontools-5.37-cloexec.patch ---
--- smartmontools-5.37/os_linux.cpp.fix	2006-10-25 19:01:42.000000000 +0200
+++ smartmontools-5.37/os_linux.cpp	2007-02-27 13:20:55.000000000 +0100
@@ -190,14 +190,14 @@
 
 // equivalent to open(path, flags)
 int deviceopen(const char *pathname, char *type){
+  int fd = -1;
   if (!strcmp(type,"SCSI")) {
-    int fd = open(pathname, O_RDWR | O_NONBLOCK);
+    fd = open(pathname, O_RDWR | O_NONBLOCK);
     if (fd < 0 && errno == EROFS)
       fd = open(pathname, O_RDONLY | O_NONBLOCK);
-    return fd;
   }
   else if (!strcmp(type,"ATA")) 
-    return open(pathname, O_RDONLY | O_NONBLOCK);
+    fd = open(pathname, O_RDONLY | O_NONBLOCK);
   else if (!strcmp(type,"ATA_3WARE_9000")) {
     // the device nodes for this controller are dynamically assigned,
     // so we need to check that they exist with the correct major
@@ -207,7 +207,7 @@
         errno=ENXIO;
       return -1;
     }
-    return open(pathname, O_RDONLY | O_NONBLOCK);
+    fd = open(pathname, O_RDONLY | O_NONBLOCK);
   }
   else if (!strcmp(type,"ATA_3WARE_678K")) {
     // the device nodes for this controller are dynamically assigned,
@@ -218,15 +218,19 @@
         errno=ENXIO;
       return -1;
     }
-    return open(pathname, O_RDONLY | O_NONBLOCK);
+    fd = open(pathname, O_RDONLY | O_NONBLOCK);
   }
   else if(!strcmp(type, "CCISS")) {
     // the device is a cciss smart array device.
-    return open(pathname, O_RDWR | O_NONBLOCK);
+    fd = open(pathname, O_RDWR | O_NONBLOCK);
   }
   else
     return -1;
 
+  if (fd != -1) {
+    fcntl(fd, F_SETFD, FD_CLOEXEC);
+  }
+  return fd;
 }
 
 // equivalent to close(file descriptor)


Index: .cvsignore
===================================================================
RCS file: /cvs/dist/rpms/smartmontools/FC-6/.cvsignore,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- .cvsignore	11 May 2006 07:54:10 -0000	1.4
+++ .cvsignore	25 Apr 2007 12:58:35 -0000	1.5
@@ -1 +1,2 @@
 smartmontools-5.36.tar.gz
+smartmontools-5.37.tar.gz


Index: smartd.initd
===================================================================
RCS file: /cvs/dist/rpms/smartmontools/FC-6/smartd.initd,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- smartd.initd	13 Dec 2006 13:19:43 -0000	1.4
+++ smartd.initd	25 Apr 2007 12:58:35 -0000	1.5
@@ -78,6 +78,7 @@
 	    ;;
 	status)
 	    status $prog
+	    RETVAL=$?
 	    ;;
 	*)
 	    echo $"Usage: $0 {start|stop|reload|report|restart|status}"


Index: smartmontools.spec
===================================================================
RCS file: /cvs/dist/rpms/smartmontools/FC-6/smartmontools.spec,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- smartmontools.spec	13 Dec 2006 13:19:43 -0000	1.24
+++ smartmontools.spec	25 Apr 2007 12:58:35 -0000	1.25
@@ -1,19 +1,16 @@
 Summary:	Tools for monitoring SMART capable hard disks
 Name:		smartmontools
-Version:	5.36
-Release: 	3.2%{?dist}
+Version:	5.37
+Release: 	1%{?dist}
 Epoch:		1
 Group:		System Environment/Base
 License:	GPL
 URL:		http://smartmontools.sourceforge.net/
 Source0:	http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
-Source1:	http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz.asc
-Source2:	smartd.initd
-Source3:	smartd-conf.py
-Source4:	smartmontools.sysconf
-Patch1:		http://people.fedora.de/rsc/smartmontools-5.36-cciss.patch
-Patch2:		smartmontools-5.36-cloexec.patch
-Patch3:		smartmontools-5.36-sata.patch
+Source1:	smartd.initd
+Source2:	smartd-conf.py
+Source3:	smartmontools.sysconf
+Patch1:		smartmontools-5.37-cloexec.patch
 
 BuildRoot:	%{_tmppath}/%{name}-%{version}-root
 PreReq:		/sbin/chkconfig /sbin/service
@@ -32,9 +29,7 @@
 
 %prep
 %setup -q
-%patch1 -p1 -b .cciss
-%patch2 -p1 -b .cloexec
-%patch3 -p1 -b .sata
+%patch1 -p1 -b .cloexec
 
 %build
 %configure
@@ -46,9 +41,9 @@
 
 rm -f $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/smartd.conf
 rm -f examplescripts/Makefile*
-install -D -m 755 %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/smartd
-install -D -m 755 %{SOURCE3} $RPM_BUILD_ROOT%{_sbindir}/smartd-conf.py
-install -D -m 644 %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/smartmontools
+install -D -m 755 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/smartd
+install -D -m 755 %{SOURCE2} $RPM_BUILD_ROOT%{_sbindir}/smartd-conf.py
+install -D -m 644 %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/smartmontools
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -80,6 +75,10 @@
 
 
 %changelog
+* Wed Apr 25 2007 Tomas Smetana <tsmetana at redhat.com> - 1:5.36-3.2
+- new upstream version (#237399)
+- return correct value from init script (#237531)
+
 * Wed Dec 13 2006 Tomas Mraz <tmraz at redhat.com> - 1:5.36-3.2
 - make descripton in init script recognizable by s-c-services (#217591)
 


Index: sources
===================================================================
RCS file: /cvs/dist/rpms/smartmontools/FC-6/sources,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- sources	11 May 2006 07:54:10 -0000	1.3
+++ sources	25 Apr 2007 12:58:35 -0000	1.4
@@ -1 +1 @@
-2e424f2d35efa38a29ebca419c1dbe3c  smartmontools-5.36.tar.gz
+4ab3668b7d1362ce923f64a211e0e568  smartmontools-5.37.tar.gz




More information about the fedora-cvs-commits mailing list