diff options
author | hunt <hunt> | 2005-07-01 18:57:52 +0000 |
---|---|---|
committer | hunt <hunt> | 2005-07-01 18:57:52 +0000 |
commit | eb703a46c2c7118700a54f632d8eb3ae03c61681 (patch) | |
tree | a1dc6e26c37526e7228b0b3d0f303c46387c44f5 /runtime | |
parent | 20c6c071f5dfe6942438d97364e74f424217c94b (diff) | |
download | systemtap-steved-eb703a46c2c7118700a54f632d8eb3ae03c61681.tar.gz systemtap-steved-eb703a46c2c7118700a54f632d8eb3ae03c61681.tar.xz systemtap-steved-eb703a46c2c7118700a54f632d8eb3ae03c61681.zip |
2005-07-01 Martin Hunt <hunt@redhat.com>
* librelay.c: Removed the color coding of cpu output.
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/stpd/ChangeLog | 4 | ||||
-rw-r--r-- | runtime/stpd/librelay.c | 16 |
2 files changed, 7 insertions, 13 deletions
diff --git a/runtime/stpd/ChangeLog b/runtime/stpd/ChangeLog index 1a260443..7469afee 100644 --- a/runtime/stpd/ChangeLog +++ b/runtime/stpd/ChangeLog @@ -1,3 +1,7 @@ +2005-07-01 Martin Hunt <hunt@redhat.com> + + * librelay.c: Removed the color coding of cpu output. + 2005-06-28 Martin Hunt <hunt@redhat.com> * librelay.c (merge_output): Use unlocked stdio diff --git a/runtime/stpd/librelay.c b/runtime/stpd/librelay.c index f997981b..e6823af1 100644 --- a/runtime/stpd/librelay.c +++ b/runtime/stpd/librelay.c @@ -123,16 +123,6 @@ static struct buf_status unsigned max_backlog; /* max # sub-buffers ready at one time */ } status[NR_CPUS]; -/* colors for printing */ -static char *color[] = { - "\033[31m", /* red */ - "\033[32m", /* green */ - "\033[33m", /* yellow */ - "\033[34m", /* blue */ - "\033[35m", /* magenta */ - "\033[36m", /* cyan */ -}; - /** * streaming - is the current transport mode streaming or not? * @@ -212,7 +202,7 @@ static void summarize(void) printf("summary:\n"); for (i = 0; i < ncpus; i++) { - printf("%s cpu %u:\n", color[i % 4], i); + printf("cpu %u:\n", i); printf(" %u sub-buffers processed\n", status[i].info.consumed); printf(" %u max backlog\n", status[i].max_backlog); @@ -571,7 +561,8 @@ static int merge_output(void) for (i = 0; i < ncpus; i++) fclose (fp[i]); fclose (ofp); - printf ("sequence had %d drops\n", dropped); + if (dropped) + printf ("\033[33mSequence had %d drops.\033[0m\n", dropped); return 0; } @@ -674,7 +665,6 @@ int stp_main_loop(void) break; case STP_REALTIME_DATA: ptr = NLMSG_DATA(nlh); - fputs ( color[5], stdout); fputs ((char *)ptr, stdout); break; case STP_EXIT: |