From a180652287e12749e0d3de82b92edc2f05b351ca Mon Sep 17 00:00:00 2001 From: Disconnect3d Date: Mon, 13 Apr 2020 16:12:18 +0200 Subject: Fix wrong argument size passed to --parent-pid strncmp check This PR fixes wrong size argument passed in `strncmp(arg, "--parent-pid", 10)` as the `"--parent-pid"` string has length of 12. --- mysql-test/lib/My/SafeProcess/safe_process_win.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mysql-test/lib/My/SafeProcess/safe_process_win.cc b/mysql-test/lib/My/SafeProcess/safe_process_win.cc index 7d81bf1a1b4..4dd4e24f30d 100644 --- a/mysql-test/lib/My/SafeProcess/safe_process_win.cc +++ b/mysql-test/lib/My/SafeProcess/safe_process_win.cc @@ -206,7 +206,7 @@ int main(int argc, const char** argv ) } else { if (strcmp(arg, "--verbose") == 0) verbose++; - else if (strncmp(arg, "--parent-pid", 10) == 0) + else if (strncmp(arg, "--parent-pid", 12) == 0) { /* Override parent_pid with a value provided by user */ const char* start; -- cgit v1.2.1