Hello community,
here is the log from the commit of package safte-monitor
checked in at Tue Jul 4 13:20:58 CEST 2006.
--------
--- safte-monitor/safte-monitor.changes 2006-05-27 19:27:01.000000000 +0200
+++ safte-monitor/safte-monitor.changes 2006-07-04 09:22:08.000000000 +0200
@@ -1,0 +2,5 @@
+Tue Jul 4 09:22:05 CEST 2006 - aj@suse.de
+
+- Fix build.
+
+-------------------------------------------------------------------
New:
----
safte-monitor-fix.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ safte-monitor.spec ++++++
--- /var/tmp/diff_new_pack.7MsPmD/_old 2006-07-04 13:20:40.000000000 +0200
+++ /var/tmp/diff_new_pack.7MsPmD/_new 2006-07-04 13:20:40.000000000 +0200
@@ -14,10 +14,11 @@
Obsoletes: saftemon
Summary: Linux SAF-TE SCSI enclosure monitor
Version: 0.0.5
-Release: 247
+Release: 248
URL: http://oss.metaparadigm.com/safte-monitor/
Source0: %{name}-%{version}.tar.gz
Patch0: %{name}-%{version}.diff
+Patch1: safte-monitor-fix.patch
License: GPL
Group: System/Monitoring
BuildRoot: %{_tmppath}/%{name}-%{version}-build
@@ -47,6 +48,7 @@
%prep
%setup -q
%patch -p1
+%patch1 -p0
%build
rm -f config.cache config.log config.status
@@ -94,6 +96,8 @@
/var/log/safte-monitor
%changelog -n safte-monitor
+* Tue Jul 04 2006 - aj@suse.de
+- Fix build.
* Sat May 27 2006 - schwab@suse.de
- Use RPM_OPT_FLAGS.
- Don't strip binaries.
++++++ safte-monitor-0.0.5.diff ++++++
--- /var/tmp/diff_new_pack.7MsPmD/_old 2006-07-04 13:20:40.000000000 +0200
+++ /var/tmp/diff_new_pack.7MsPmD/_new 2006-07-04 13:20:40.000000000 +0200
@@ -159,10 +159,11 @@
+SAFTEMONITOR_OPTIONS="-A /etc/safte-monitor/alert"
--- safte-monitor-0.0.5/src/qlogic_api.c
+++ safte-monitor-0.0.5/src/qlogic_api.c
-@@ -1,5 +1,6 @@
+@@ -1,5 +1,7 @@
#include
#include
+#include
++#include
#include "scsi_api.h"
#include "qlogic_api.h"
++++++ safte-monitor-fix.patch ++++++
--- src/qlogic_api.c
+++ src/qlogic_api.c
@@ -13,7 +13,7 @@
static fc_device_t *qldev_head;
-int qlogic_probe(int fd)
+void qlogic_probe(int fd)
{
QL_IOCTL ql;
QL_DISC_PORT qlport;
@@ -24,7 +24,9 @@
if(qldev_head) return; /* already probed */
if(msizeof(QL_IOCTL, Signature) == 4)
- strcpy((char*)&ql.Signature, "QLOG");
+ /* We do not NUL-terminate ql.Signature, otherwise we write beyond the
+ end of the string. */
+ strncpy((char*)&ql.Signature, "QLOG", 4);
else if(msizeof(QL_IOCTL, Signature) == 8)
strcpy((char*)&ql.Signature, "QLOGIC");
ql.Version = QL_VERSION;
@@ -95,7 +97,7 @@
while(qldev->next) {
for(lun=0; lun<256; lun++) {
/* all luns have the same WWPN */
- if(scsidev = find_dev_by_loc(qldev->host, 0, qldev->id, lun)) {
+ if((scsidev = find_dev_by_loc(qldev->host, 0, qldev->id, lun))) {
scsidev->isfc = 1;
strcpy(scsidev->wwpn, qldev->wwpn);
strcpy(scsidev->wwnn, qldev->wwnn);
--- src/qlogic_api.h
+++ src/qlogic_api.h
@@ -3,7 +3,7 @@
#include
-extern int qlogic_probe(int fd);
+extern void qlogic_probe(int fd);
extern int qlogic_map_wwn_to_sd();
extern void qlogic_free();
--- src/safte-monitor.c
+++ src/safte-monitor.c
@@ -209,7 +209,8 @@
return 0;
}
-int get_safte_device_insertions(int fd, safte_device_t *safte_dev)
+static void
+get_safte_device_insertions(int fd, safte_device_t *safte_dev)
{
unsigned char* buf;
int i, k;
@@ -222,7 +223,8 @@
}
-int get_safte_device_slot_status(int fd, safte_device_t *safte_dev)
+static void
+get_safte_device_slot_status(int fd, safte_device_t *safte_dev)
{
unsigned char* buf;
int i, k;
@@ -238,7 +240,7 @@
}
-
+#if 0
int map_slots_to_devices()
{
int i;
@@ -263,7 +265,7 @@
scsidev = scsidev->next;
}
}
-
+#endif
int scan_safte_devices()
{
@@ -635,7 +637,7 @@
}
-int check_safte_status()
+void check_safte_status(void)
{
int fd, s;
safte_device_t *saftedev = saftedev_head;
--- src/safte-monitor.h
+++ src/safte-monitor.h
@@ -137,6 +137,9 @@
char *desc;
} safte_status_code_t;
+
+extern void check_safte_status(void);
+
#endif
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit-unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit-help@opensuse.org