aboutsummaryrefslogtreecommitdiffstats
path: root/src/firemon/cpu.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/firemon/cpu.c')
-rw-r--r--src/firemon/cpu.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/firemon/cpu.c b/src/firemon/cpu.c
index 2a6979573..7d31cd44d 100644
--- a/src/firemon/cpu.c
+++ b/src/firemon/cpu.c
@@ -33,7 +33,7 @@ static void print_cpu(int pid) {
33 free(file); 33 free(file);
34 return; 34 return;
35 } 35 }
36 36
37 char buf[MAXBUF]; 37 char buf[MAXBUF];
38 while (fgets(buf, MAXBUF, fp)) { 38 while (fgets(buf, MAXBUF, fp)) {
39 if (strncmp(buf, "Cpus_allowed_list:", 18) == 0) { 39 if (strncmp(buf, "Cpus_allowed_list:", 18) == 0) {
@@ -45,10 +45,10 @@ static void print_cpu(int pid) {
45 fclose(fp); 45 fclose(fp);
46 free(file); 46 free(file);
47} 47}
48 48
49void cpu(pid_t pid, int print_procs) { 49void cpu(pid_t pid, int print_procs) {
50 pid_read(pid); 50 pid_read(pid);
51 51
52 // print processes 52 // print processes
53 int i; 53 int i;
54 for (i = 0; i < max_pids; i++) { 54 for (i = 0; i < max_pids; i++) {
@@ -62,4 +62,3 @@ void cpu(pid_t pid, int print_procs) {
62 } 62 }
63 printf("\n"); 63 printf("\n");
64} 64}
65