diff --git a/lshw-B.02.14-gcc45.patch b/lshw-B.02.14-gcc45.patch deleted file mode 100644 index b259884..0000000 --- a/lshw-B.02.14-gcc45.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- lshw-B.02.14/src/core/scsi.cc~ 2010-09-05 19:36:47.411010711 +0200 -+++ lshw-B.02.14/src/core/scsi.cc 2010-09-05 19:02:19.148903622 +0200 -@@ -842,7 +842,7 @@ - - if (!controller) - { -- controller = node.addChild(hwNode::hwNode("scsi", hw::storage)); -+ controller = node.addChild(hwNode("scsi", hw::storage)); - if (controller) - { - controller->setLogicalName(host_logicalname(number)); diff --git a/lshw-B.02.17-scan-fat-mem-bug.patch b/lshw-B.02.17-scan-fat-mem-bug.patch new file mode 100644 index 0000000..feed00e --- /dev/null +++ b/lshw-B.02.17-scan-fat-mem-bug.patch @@ -0,0 +1,20 @@ +------------------------------------------------------------------------ +r2528 | lyonel | 2013-08-24 18:12:05 +0200 (lø., 24 aug. 2013) | 2 lines + +fix #632: ensure that FAT superblock is at least 1 sector long + + +Index: src/core/fat.cc +=================================================================== +--- src/core/fat.cc (revisjon 2527) ++++ src/core/fat.cc (revisjon 2528) +@@ -81,6 +81,7 @@ + uint8_t dummy2[164]; + uint8_t pmagic[2]; + } __attribute__((__packed__)) fat32; ++ char sector[512]; // to make sure the whole struct is at least 512 bytes long + } __attribute__((__packed__)) type; + } __attribute__((__packed__)); + + +------------------------------------------------------------------------ diff --git a/lshw-ext4.patch b/lshw-ext4.patch deleted file mode 100644 index 4ffd832..0000000 --- a/lshw-ext4.patch +++ /dev/null @@ -1,23 +0,0 @@ -Index: src/core/hw.cc -=================================================================== ---- src/core/hw.cc (revision 2143) -+++ src/core/hw.cc (revision 2144) -@@ -47,13 +47,17 @@ - string hw::strip(const string & s) - { - string result = s; -+ size_t i = result.find('\0'); - -+ if(i != string::npos) -+ result = result.substr(0, i); -+ - while ((result.length() > 0) && ((uint8_t)result[0] <= ' ')) - result.erase(0, 1); - while ((result.length() > 0) && ((uint8_t)result[result.length() - 1] <= ' ')) - result.erase(result.length() - 1); - -- for (unsigned int i = 0; i < result.length(); i++) -+ for (i = 0; i < result.length(); i++) - if ((uint8_t)result[i] < ' ') - { - result.erase(i, 1); diff --git a/lshw.spec b/lshw.spec index c7a7ee6..a0dbbfd 100644 --- a/lshw.spec +++ b/lshw.spec @@ -1,11 +1,11 @@ %if 0%{?fedora} <= 18 -%global vendortag 1 +%global vendortag 1 %endif Summary: Hardware lister Name: lshw Version: B.02.17 -Release: 1%{?dist} +Release: 2%{?dist} License: GPLv2 Group: Applications/System URL: http://ezix.org/project/wiki/HardwareLiSter @@ -13,8 +13,8 @@ Source0: http://www.ezix.org/software/files/lshw-%{version}.tar.gz Source1: lshw.desktop Source2: org.ezix.lshw.gui.policy Source3: lshw-gui +Patch0: lshw-B.02.17-scan-fat-mem-bug.patch BuildRequires: sqlite-devel -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: hwdata %description @@ -41,6 +41,7 @@ plain, XML or HTML format. %prep %setup -q +%patch0 -p0 %build %{__make} %{?_smp_mflags} SBINDIR="%{_sbindir}" RPM_OPT_FLAGS="%{optflags}" SQLITE=1 gui @@ -50,7 +51,6 @@ pushd src %{__make} nologo %install -%{__rm} -rf %{buildroot} %{__make} install \ DESTDIR="%{buildroot}" \ PREFIX="%{_prefix}" \ @@ -94,18 +94,13 @@ desktop-file-install %{?vendortag:--vendor fedora} \ #find_lang %{name} rm -rf %{buildroot}%{_datadir}/locale/fr/ -%clean -%{__rm} -rf %{buildroot} - #files -f %{name}.lang %files -%defattr(-, root, root, -) %doc COPYING README docs/* %doc %{_mandir}/man1/lshw.1* %{_sbindir}/%{name} %files gui -%defattr(-, root, root, -) %doc COPYING %{_bindir}/%{name}-gui %{_sbindir}/gtk-%{name} @@ -116,6 +111,9 @@ rm -rf %{buildroot}%{_datadir}/locale/fr/ %{_datadir}/polkit-1/actions/org.ezix.lshw.gui.policy %changelog +* Mon Sep 30 2013 Terje Rosten - B.02.17-2 +- Add patch to fix segfault in scan fat code + * Thu Sep 26 2013 Terje Rosten - B.02.17-1 - B.02.17