• Skip to sidebar navigation
  • Skip to content

Bitbucket

  • More
    ProjectsRepositories
  • Help
    • Online help
    • Learn Git
    • Welcome to Bitbucket
    • Keyboard shortcuts
  • Log In
Alexander Dahl
  1. Alexander Dahl

buildroot

Public
Actions
  • Clone
  • Compare

Learn more about cloning repositories

You have read-only access

Navigation
  • Source
  • Commits
  • Branches
  • All Branches Graph
  • Forks
  1. Alexander Dahl
  2. buildroot

Source

buildroot/package/iostat/iostat-cpunum.patch
Gustavo ZacariasGustavo Zacarias committed ee77963588b22 Jul 2010
Raw file
Source viewDiff to previous
xxxxxxxxxx
 
1
From bf646965f75cdad77a45fa3b0046e093b202b2ce Mon Sep 17 00:00:00 2001
2
From: Gustavo Zacarias <gustavo@zacarias.com.ar>
3
Date: Thu, 22 Jul 2010 12:42:10 -0300
4
Subject: [PATCH] Make cpu number counter more reliable
5
​
6
​
7
Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
8
---
9
 iostat.c |    2 +-
10
 1 files changed, 1 insertions(+), 1 deletions(-)
11
​
12
diff --git a/iostat.c b/iostat.c
13
index 13e2af7..5d74085 100644
14
--- a/iostat.c
15
+++ b/iostat.c
16
@@ -140,7 +140,7 @@ void get_number_of_cpus()
17
 
18
    handle_error("Can't open /proc/cpuinfo", !ncpufp);
19
    while (fgets(buffer, sizeof(buffer), ncpufp)) {
20
-       if (!strncmp(buffer, "processor\t:", 11))
21
+       if (!strncasecmp(buffer, "processor\t", 10))
22
            ncpu++;
23
    }
24
    fclose(ncpufp);
25
-- 
26
1.7.1
27
​
  • Git repository management for enterprise teams powered by Atlassian Bitbucket
  • Atlassian Bitbucket v6.7.2
  • Documentation
  • Request a feature
  • About
  • Contact Atlassian
Atlassian

Everything looks good. We'll let you know here if there's anything you should know about.