Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 323761
b: refs/heads/master
c: be4a2de
h: refs/heads/master
i:
  323759: c5ba90a
v: v3
  • Loading branch information
Namhyung Kim authored and Arnaldo Carvalho de Melo committed Sep 5, 2012
1 parent 16a6860 commit 3038a86
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 618a3f1d30ea0ee2ff3a88661b8d6a4035123211
refs/heads/master: be4a2dedf6816871349fbddd018f266e93e3c22d
6 changes: 6 additions & 0 deletions trunk/tools/perf/util/header.c
Original file line number Diff line number Diff line change
Expand Up @@ -1440,6 +1440,9 @@ static void print_pmu_mappings(struct perf_header *ph, int fd, FILE *fp)
if (ret != sizeof(pmu_num))
goto error;

if (ph->needs_swap)
pmu_num = bswap_32(pmu_num);

if (!pmu_num) {
fprintf(fp, "# pmu mappings: not available\n");
return;
Expand All @@ -1448,6 +1451,9 @@ static void print_pmu_mappings(struct perf_header *ph, int fd, FILE *fp)
while (pmu_num) {
if (read(fd, &type, sizeof(type)) != sizeof(type))
break;
if (ph->needs_swap)
type = bswap_32(type);

name = do_read_string(fd, ph);
if (!name)
break;
Expand Down

0 comments on commit 3038a86

Please sign in to comment.