From 69e331f55917e31c3bc483bbadfd63b49afb253f Mon Sep 17 00:00:00 2001 From: Roman Rakus Date: Wed, 2 Jun 2010 12:50:44 +0000 Subject: [PATCH] correct the parameter checking when attempting to set the run mode --- powerpc-utils-cpu_diag_mode.patch | 13 +++++++++++++ powerpc-utils.spec | 13 +++++++++++-- 2 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 powerpc-utils-cpu_diag_mode.patch diff --git a/powerpc-utils-cpu_diag_mode.patch b/powerpc-utils-cpu_diag_mode.patch new file mode 100644 index 0000000..8a42648 --- /dev/null +++ b/powerpc-utils-cpu_diag_mode.patch @@ -0,0 +1,13 @@ +Index: powerpc-utils-1.2.2/src/ppc64_cpu.c +=================================================================== +--- powerpc-utils-1.2.2.orig/src/ppc64_cpu.c 2009-10-22 14:00:13.000000000 -0500 ++++ powerpc-utils-1.2.2/src/ppc64_cpu.c 2010-05-17 14:29:45.577267014 -0500 +@@ -383,7 +383,7 @@ + } else { + signed char rmode = *run_mode; + +- if (rmode < 0 || rmode > 3) { ++ if (rmode < '0' || rmode > '3') { + printf("Invalid run-mode=%c\n", rmode); + return -1; + } diff --git a/powerpc-utils.spec b/powerpc-utils.spec index 05385e3..da57f26 100644 --- a/powerpc-utils.spec +++ b/powerpc-utils.spec @@ -1,6 +1,6 @@ Name: powerpc-utils Version: 1.2.2 -Release: 2%{?dist} +Release: 4%{?dist} Summary: Utilities for PowerPC platforms Group: System Environment/Base @@ -16,7 +16,10 @@ Requires: libservicelog ExclusiveArch: ppc ppc64 # This hack is needed only for platforms with autoconf < 2.63 -Patch2: powerpc-utils-autoconf.patch +Patch1: powerpc-utils-autoconf.patch + +# correct the parameter checking when attempting to set the run mode +Patch2: powerpc-utils-cpu_diag_mode.patch # This is done before release of F12 Obsoletes: powerpc-utils-papr < 1.1.6-3 @@ -33,6 +36,8 @@ Utilities for PowerPC platforms. %patch1 -p1 -b .aconf %endif +%patch2 -p1 -b .cpu_diag_mode + %build ./bootstrap.sh %configure @@ -109,6 +114,10 @@ rm -rf $RPM_BUILD_ROOT %preun %changelog +* Wed Jun 02 2010 Roman Rakus - 1.2.2-4 +- correct the parameter checking when attempting to set the run mode +- also bump release + * Fri Mar 05 2010 Roman Rakus - 1.2.2-2 - Removed deprecated init script and perl script