rpms/cpufrequtils/devel aperf-fix-proc-read-routine.patch, NONE, 1.1 cpufrequtils-fix-parallel-build-of-ccdv.patch, 1.1, NONE
Anton Arapov
aarapov at fedoraproject.org
Wed Nov 11 10:40:11 UTC 2009
Author: aarapov
Update of /cvs/pkgs/rpms/cpufrequtils/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv24963
Added Files:
aperf-fix-proc-read-routine.patch
Removed Files:
cpufrequtils-fix-parallel-build-of-ccdv.patch
Log Message:
New upstream release
aperf-fix-proc-read-routine.patch:
aperf.c | 18 +++++++-----------
1 file changed, 7 insertions(+), 11 deletions(-)
--- NEW FILE aperf-fix-proc-read-routine.patch ---
--- cpufrequtils-006/utils/aperf.c.orig 2009-11-11 10:11:46.068391593 +0100
+++ cpufrequtils-006/utils/aperf.c 2009-11-11 10:53:07.812489952 +0100
@@ -76,14 +76,15 @@ static unsigned int count_cpus(void)
unsigned int cpunr = 0;
fp = fopen("/proc/stat", "r");
- if(!fp)
- goto err_out;
+ if(!fp) {
+ printf("Couldn't count the number of CPUs (%s: %s), "
+ "assuming 1\n", "/proc/stat", strerror(errno));
+ return 1;
+ }
while (!feof(fp)) {
- if (!fgets(value, LINE_LEN, fp)) {
- fclose(fp);
- goto err_out;
- }
+ if (!fgets(value, LINE_LEN, fp))
+ continue;
value[LINE_LEN - 1] = '\0';
if (strlen(value) < (LINE_LEN - 2))
continue;
@@ -98,11 +99,6 @@ static unsigned int count_cpus(void)
/* cpu count starts from 0, on error return 1 (UP) */
return (ret+1);
-
-err_out:
- printf("Couldn't count the number of CPUs (%s: %s), "
- "assuming 1\n", "/proc/stat", strerror(errno));
- return 1;
}
static int has_mperf_aperf_support(int cpu)
--- cpufrequtils-fix-parallel-build-of-ccdv.patch DELETED ---
More information about the fedora-extras-commits
mailing list