From e8f28179b0cbceefa8951c4879db80369cce0045 Mon Sep 17 00:00:00 2001 From: Masakazu Kitajo Date: Wed, 22 Feb 2023 19:01:15 -0700 Subject: [PATCH] Fix parameter parser in ssl_hook_test plugin --- tests/tools/plugins/ssl_hook_test.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/tools/plugins/ssl_hook_test.cc b/tests/tools/plugins/ssl_hook_test.cc index 20be7822b36..c549c394b92 100644 --- a/tests/tools/plugins/ssl_hook_test.cc +++ b/tests/tools/plugins/ssl_hook_test.cc @@ -246,11 +246,11 @@ parse_callbacks(int argc, const char *argv[], int &preaccept_count, int &client_ ptr = index(argv[i], '='); if (ptr) { if (strncmp(argv[i] + 1, "close", strlen("close")) == 0) { - close_count = atoi(ptr + i); + close_count = atoi(ptr + 1); } else if (strncmp(argv[i] + 1, "client_hello_imm", strlen("client_hello_imm")) == 0) { - client_hello_count_immediate = atoi(ptr + i); + client_hello_count_immediate = atoi(ptr + 1); } else if (strncmp(argv[i] + 1, "client_hello", strlen("client_hello")) == 0) { - client_hello_count = atoi(ptr + i); + client_hello_count = atoi(ptr + 1); } else { cert_count = atoi(ptr + 1); }