Browse Source
Added 'const' to arguments in get_one_option and find_typeset()
Added 'const' to arguments in get_one_option and find_typeset()
One should not change the program arguments! This change also reduces warnings from the icc compiler. Almost all changes are just syntax changes (adding const to 'get_one_option function' declarations). Other changes: - Added a few cast of 'argument' from 'const char*' to 'char *'. This was mainly in calls to 'external' functions we don't have control of. - Ensure that all reset of 'password command line argument' are similar. (In almost all cases it was just adding a comment and a cast) - In mysqlbinlog.cc and mysqld.cc there was a few cases that changed the command line argument. These places where changed to instead allocate the option in a MEM_ROOT to avoid changing the argument. Some of this code was changed to ensure that different programs did parsing the same way. Added a test case for the changes in mysqlbinlog.cc - Changed a few variables that took their value from command line options from 'char *' to 'const char *'.pull/1754/head
53 changed files with 296 additions and 161 deletions
-
2client/mariadb-conv.cc
-
16client/mysql.cc
-
3client/mysql_plugin.c
-
11client/mysql_upgrade.c
-
13client/mysqladmin.cc
-
57client/mysqlbinlog.cc
-
12client/mysqlcheck.c
-
16client/mysqldump.c
-
11client/mysqlimport.c
-
11client/mysqlshow.c
-
11client/mysqlslap.c
-
12client/mysqltest.cc
-
2extra/comp_err.c
-
2extra/innochecksum.cc
-
4extra/mariabackup/innobackupex.cc
-
7extra/mariabackup/xbstream.cc
-
11extra/mariabackup/xtrabackup.cc
-
2extra/mariabackup/xtrabackup.h
-
2extra/my_print_defaults.c
-
2extra/mysql_waitpid.c
-
2extra/perror.c
-
2extra/resolve_stack_dump.c
-
2extra/resolveip.c
-
2include/my_getopt.h
-
3include/mysql.h.pp
-
3include/typelib.h
-
18mysql-test/main/mysqlbinlog.result
-
28mysql-test/main/mysqlbinlog.test
-
4mysys/typelib.c
-
2sql/mysql_install_db.cc
-
2sql/mysql_upgrade_service.cc
-
111sql/mysqld.cc
-
6sql/sql_plugin.cc
-
3sql/sql_show.cc
-
2sql/sql_show.h
-
5sql/tztime.cc
-
3storage/maria/aria_chk.c
-
2storage/maria/aria_dump_log.c
-
5storage/maria/aria_ftdump.c
-
3storage/maria/aria_pack.c
-
3storage/maria/aria_read_log.c
-
2storage/maria/aria_s3_copy.cc
-
2storage/maria/ma_rt_test.c
-
2storage/maria/ma_test1.c
-
2storage/maria/unittest/ma_control_file-t.c
-
2storage/maria/unittest/ma_test_loghandler_multigroup-t.c
-
2storage/myisam/mi_test1.c
-
5storage/myisam/myisam_ftdump.c
-
2storage/myisam/myisamchk.c
-
3storage/myisam/myisampack.c
-
2tests/async_queries.c
-
11tests/mysql_client_fw.c
-
4unittest/mysys/my_getopt-t.c
Write
Preview
Loading…
Cancel
Save
Reference in new issue