1Fix gcc7 compile 2 3mysql.cc: In function 'void build_completion_hash(bool, bool)': 4mysql.cc:2687:37: error: invalid conversion from 'char' to 'char*' [-fpermissive] 5 field_names[i][num_fields*2]= '\0'; 6 ^~~~ 7Patch was partly backported from upstream commit: 8https://github.com/mysql/mysql-server/commit/ae21683d980d5fe9e39bd0193827ea3604256eb9 9 10Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> 11[Thomas: add more gcc 7.x fixes in instance_map.cc.] 12Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> 13 14Index: b/client/mysql.cc 15=================================================================== 16--- a/client/mysql.cc 17+++ b/client/mysql.cc 18@@ -2684,7 +2684,7 @@ 19 mysql_free_result(fields); 20 break; 21 } 22- field_names[i][num_fields*2]= '\0'; 23+ field_names[i][num_fields*2]= NULL; 24 j=0; 25 while ((sql_field=mysql_fetch_field(fields))) 26 { 27Index: b/server-tools/instance-manager/instance_map.cc 28=================================================================== 29--- a/server-tools/instance-manager/instance_map.cc 30+++ b/server-tools/instance-manager/instance_map.cc 31@@ -526,12 +526,12 @@ 32 Options::Main::config_file); 33 34 argv_options[1]= defaults_file_arg; 35- argv_options[2]= '\0'; 36+ argv_options[2]= NULL; 37 38 argc= 2; 39 } 40 else 41- argv_options[1]= '\0'; 42+ argv_options[1]= NULL; 43 44 /* 45 If the routine failed, we'll simply fallback to defaults in 46