2013-08-29 13:31:03 +00:00
|
|
|
diff --git a/misc/lnstat.c b/misc/lnstat.c
|
|
|
|
index dca10ad..2889e5e 100644
|
|
|
|
--- a/misc/lnstat.c
|
|
|
|
+++ b/misc/lnstat.c
|
|
|
|
@@ -226,7 +226,7 @@ int main(int argc, char **argv)
|
|
|
|
MODE_NORMAL,
|
|
|
|
} mode = MODE_NORMAL;
|
|
|
|
|
|
|
|
- unsigned long count = 1;
|
|
|
|
+ unsigned long count = 0;
|
|
|
|
static struct field_params fp;
|
|
|
|
int num_req_files = 0;
|
|
|
|
char *req_files[LNSTAT_MAX_FILES];
|
|
|
|
@@ -336,13 +336,14 @@ int main(int argc, char **argv)
|
|
|
|
if (interval < 1 )
|
|
|
|
interval=1;
|
|
|
|
|
|
|
|
- for (i = 0; i < count; i++) {
|
|
|
|
+ for (i = 0; !count || i < count; ) {
|
|
|
|
if ((hdr > 1 && (! (i % 20))) || (hdr == 1 && i == 0))
|
|
|
|
print_hdr(stdout, header);
|
|
|
|
lnstat_update(lnstat_files);
|
|
|
|
print_line(stdout, lnstat_files, &fp);
|
|
|
|
fflush(stdout);
|
|
|
|
sleep(interval);
|
2013-08-30 09:10:40 +00:00
|
|
|
+ if (count) ++i;
|
2013-08-29 13:31:03 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|