Accepting request 41775 from Base:System

Copy from Base:System/numactl based on submit request 41775 from user trenn

OBS-URL: https://build.opensuse.org/request/show/41775
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/numactl?expand=0&rev=24
This commit is contained in:
OBS User autobuild 2010-06-22 08:32:50 +00:00 committed by Git OBS Bridge
parent b0913fa4f6
commit 94a49d3f7d
5 changed files with 46 additions and 6 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:41a1809e79c4381745e11dafb19a3a1f2c62a9a3e60f374594d935a5aba6f708
size 66851

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:2f4881223fb43a4c88eb761c3b171d41974e17fa3d141477b26260288db1d502
size 66616

View File

@ -1,3 +1,13 @@
-------------------------------------------------------------------
Wed Jun 9 09:32:15 UTC 2010 - trenn@novell.com
- Fixed corrupt tar.bz2 and added a mem corruption fix from Jan.
-------------------------------------------------------------------
Thu May 20 12:07:19 UTC 2010 - trenn@novell.com
- Update to version 2.0.4-rc2
-------------------------------------------------------------------
Thu Feb 11 01:31:44 UTC 2010 - jengelh@medozas.de

View File

@ -20,11 +20,11 @@
Url: http://oss.sgi.com/projects/libnuma/
Name: numactl
License: GPLv2 ; GPLv2+
License: GPLv2+
Summary: NUMA Policy Control
Version: 2.0.4.rc1
Release: 3
%define origversion 2.0.4-rc1
Release: 4
%define origversion 2.0.4-rc2
AutoReqProv: on
# bug437293
%ifarch ppc64
@ -34,6 +34,7 @@ Obsoletes: numactl-64bit
Source: numactl-%{origversion}.tar.bz2
Source2: baselibs.conf
Patch0: numactl_install_all_manpages
Patch1: numactl_fix_mem_corrup_numa_init.patch
Group: System/Management
BuildRoot: %{_tmppath}/%{name}-%{version}-build
ExclusiveArch: ia64 x86_64 ppc64 ppc %sparc
@ -88,6 +89,7 @@ Authors:
%prep
%setup -n %{name}-%{origversion}
%patch0 -p1
%patch1 -p1
%build
make %{?jobs:-j%jobs} CFLAGS="${RPM_OPT_FLAGS}"

View File

@ -0,0 +1,28 @@
From: Jan Beulich <jbeulich@suse.de>
---
libnuma.c | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
Index: numactl-2.0.4-rc2/libnuma.c
===================================================================
--- numactl-2.0.4-rc2.orig/libnuma.c
+++ numactl-2.0.4-rc2/libnuma.c
@@ -461,10 +461,13 @@ set_task_constraints(void)
read_mask(mask, numa_all_nodes_ptr);
}
if (strncmp(buffer,"Mems_allowed_list:",18) == 0) {
- nodes_allowed_list = malloc(strlen(buffer)-18);
- strncpy(nodes_allowed_list, buffer + 19,
- strlen(buffer) - 19);
- nodes_allowed_list[strlen(nodes_allowed_list)-1] = '\0';
+ size_t len = strlen(mask);
+
+ nodes_allowed_list = malloc(len);
+ if (nodes_allowed_list) {
+ memcpy(nodes_allowed_list, mask, len-1);
+ nodes_allowed_list[len-1] = '\0';
+ }
}
}
fclose(f);