aboutsummaryrefslogtreecommitdiff
path: root/src/test/bench.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2016-07-28 06:59:03 -0400
committerNick Mathewson <nickm@torproject.org>2016-07-28 06:59:03 -0400
commita8676b1edecee2d1d472b7f67dd026ef7b084a2f (patch)
treed9ba30676becb8e03bbceaae9ba19a8288a2eb1d /src/test/bench.c
parentf0488551e7be4e2d21a104903a86be993a240398 (diff)
parent47573038736b96e2a353a25ed3c788dcb77d8fcb (diff)
downloadtor-a8676b1edecee2d1d472b7f67dd026ef7b084a2f.tar.gz
tor-a8676b1edecee2d1d472b7f67dd026ef7b084a2f.zip
Merge branch 'bug18902_squashed'
Diffstat (limited to 'src/test/bench.c')
-rw-r--r--src/test/bench.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/test/bench.c b/src/test/bench.c
index 5595988f31..f1cf715f30 100644
--- a/src/test/bench.c
+++ b/src/test/bench.c
@@ -662,7 +662,6 @@ main(int argc, const char **argv)
{
int i;
int list=0, n_enabled=0;
- benchmark_t *b;
char *errmsg;
or_options_t *options;
@@ -672,10 +671,10 @@ main(int argc, const char **argv)
if (!strcmp(argv[i], "--list")) {
list = 1;
} else {
- benchmark_t *b = find_benchmark(argv[i]);
+ benchmark_t *benchmark = find_benchmark(argv[i]);
++n_enabled;
- if (b) {
- b->enabled = 1;
+ if (benchmark) {
+ benchmark->enabled = 1;
} else {
printf("No such benchmark as %s\n", argv[i]);
}
@@ -700,7 +699,7 @@ main(int argc, const char **argv)
return 1;
}
- for (b = benchmarks; b->name; ++b) {
+ for (benchmark_t *b = benchmarks; b->name; ++b) {
if (b->enabled || n_enabled == 0) {
printf("===== %s =====\n", b->name);
if (!list)