Date: Sat, 22 May 2010 11:38:07 +0000 (UTC) From: Peter Holm <pho@FreeBSD.org> To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r208415 - in projects/stress2: include lib Message-ID: <201005221138.o4MBc7wJ044537@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: pho Date: Sat May 22 11:38:06 2010 New Revision: 208415 URL: http://svn.freebsd.org/changeset/base/208415 Log: Only print the name of the test program if run. Modified: projects/stress2/include/stress.h projects/stress2/lib/main.c projects/stress2/lib/options.c Modified: projects/stress2/include/stress.h ============================================================================== --- projects/stress2/include/stress.h Sat May 22 08:30:47 2010 (r208414) +++ projects/stress2/include/stress.h Sat May 22 11:38:06 2010 (r208415) @@ -60,6 +60,7 @@ extern void putval(unsigned long); extern unsigned long getval(void); extern void getdf(int64_t *, int64_t *); extern void reservedf(int64_t, int64_t); +extern void show_status(void); extern int64_t swap(void); extern unsigned long usermem(void); #endif Modified: projects/stress2/lib/main.c ============================================================================== --- projects/stress2/lib/main.c Sat May 22 08:30:47 2010 (r208414) +++ projects/stress2/lib/main.c Sat May 22 11:38:06 2010 (r208415) @@ -152,6 +152,8 @@ run_test(void) if (random_int(1,100) > op->load) return (status); + show_status(); + start = time(NULL); done_testing = 0; fflush(stdout); Modified: projects/stress2/lib/options.c ============================================================================== --- projects/stress2/lib/options.c Sat May 22 08:30:47 2010 (r208414) +++ projects/stress2/lib/options.c Sat May 22 11:38:06 2010 (r208415) @@ -144,9 +144,6 @@ void options(int argc, char **argv) { int ch; - int days; - time_t t; - char buf[80]; op = &opt; @@ -206,6 +203,14 @@ options(int argc, char **argv) op->run_time = 15; if (op->load < 0 || op->load > 100) op->load = 100; +} + +void +show_status(void) +{ + char buf[80]; + int days; + time_t t; if (op->verbose > 0) { t = op->run_time; @@ -218,7 +223,6 @@ options(int argc, char **argv) } } - void rmval(void) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201005221138.o4MBc7wJ044537>