Compare commits

...
Sign in to create a new pull request.

1 commit

Author SHA1 Message Date
Rafael Fonseca
9ee51785bd Fix double free on sysfs (#1414802) 2017-01-19 16:33:11 +01:00
2 changed files with 19 additions and 1 deletions

View file

@ -0,0 +1,13 @@
Index: openhpi/plugins/sysfs/sysfs2hpi.c
===================================================================
--- openhpi/plugins/sysfs/sysfs2hpi.c (revision 7664)
+++ openhpi/plugins/sysfs/sysfs2hpi.c (working copy)
@@ -571,6 +571,7 @@
if (!(sys->bus->devices)) {
err("no i2c devices found");
sysfs_close_bus(sys->bus);
+ sys->bus = NULL;
sys->initialized++;
return 0;
}

View file

@ -3,13 +3,14 @@
Summary: Hardware Platform Interface library and tools
Name: openhpi
Version: 3.6.1
Release: 2%{?dist}
Release: 3%{?dist}
License: BSD
Group: System Environment/Base
URL: http://www.openhpi.org
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
# convert from initscript to systemd unit
Patch0: %{name}-3.4.0-systemd.patch
Patch1: %{name}-3.6.1-sysfs-double-free.patch
BuildRequires: libsysfs-devel
BuildRequires: net-snmp-devel
BuildRequires: OpenIPMI-devel
@ -64,6 +65,7 @@ The development libraries and header files for the OpenHPI project.
%prep
%setup -q
%patch0 -p1 -b .systemd
%patch1 -p1 -b .sysfs
autoreconf -vif
@ -137,6 +139,9 @@ make check
%changelog
* Thu Jan 19 2017 Rafael Fonseca <rdossant@redhat.com> - 3.6.1-3
- Fix #1414802 - double free or corruption on sysfs plugin.
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 3.6.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild