diff options
author | Roland McGrath <roland@redhat.com> | 1993-08-01 20:39:38 +0000 |
---|---|---|
committer | Roland McGrath <roland@redhat.com> | 1993-08-01 20:39:38 +0000 |
commit | cbeeeafde91c78578ad5c21b4e05797c3db5d457 (patch) | |
tree | e542f6d3f84767c2862247b77324c183240a3e55 | |
parent | 572856fa8f2a9f98a0366a1f1e604be26334daae (diff) | |
download | gunmake-cbeeeafde91c78578ad5c21b4e05797c3db5d457.tar.gz |
*** empty log message ***
-rw-r--r-- | getloadavg.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/getloadavg.c b/getloadavg.c index 60036bc..ff868c2 100644 --- a/getloadavg.c +++ b/getloadavg.c @@ -810,9 +810,6 @@ main (argc, argv) if (argc > 1) naptime = atoi (argv[1]); - if (naptime == 0) - naptime = 5; - while (1) { double avg[3]; @@ -833,7 +830,12 @@ main (argc, argv) printf ("15-minute: %f ", avg[2]); if (loads > 0) putchar ('\n'); + + if (naptime == 0) + break; sleep (naptime); } + + exit (0); } #endif /* TEST */ |