An error occurred fetching the project authors.
- 29 Jun, 2012 1 commit
-
-
Jon Olav Hauglid authored
This patch fixes various compilation warnings of the type "error: narrowing conversion of 'x' from 'datatype1' to 'datatype2'
-
- 29 May, 2012 1 commit
-
-
Rohit Kalhans authored
Problem: mysqlbinlog exits without any error code in case of file write error. It is because of the fact that the calls to Log_event::print() method does not return a value and the thus any error were being ignored. Resolution: We resolve this problem by checking for the IO_CACHE::error == -1 after every call to Log_event:: print() and terminating the further execution. client/mysqlbinlog.cc: - handled error conditions during event->print() calls - added check for error in end_io_cache() mysys/my_write.c: Added debug code to simulate file write error. error returned will be ENOSPC=> error no space on the disk sql/log_event.cc: Added debug code to simulate file write error, by reducing the size of io cache.
-
- 11 Jul, 2011 1 commit
-
-
Luis Soares authored
CLIENT TOOLS The fix is to backport part of revision: - alexander.nozdrin@oracle.com-20101006150613-ls60rb2tq5dpyb5c from mysql-5.5. In detail, we add the oracle welcome notice header file proposed in the original patch and include/use it in client/mysqlbinlog.cc, replacing the existing and obsolete notice.
-
- 30 Jun, 2011 1 commit
-
-
Kent Boortz authored
-
- 06 Jun, 2011 1 commit
-
-
Georgi Kodinov authored
options.
-
- 05 May, 2011 1 commit
-
-
Luis Soares authored
WORK WITH --START-POSITION If setting --start-position to start after the FD event, mysqlbinlog will output an error stating that it has not found an FD event. However, its not that mysqlbinlog does not find it but rather that it does not processes it in the regular way (i.e., it does not print it). Given that one is using --base64-output=DECODE-ROWS then not printing it is actually fine. To fix this, we make mysqlbinlog not to complain when it has not printed the FD event, is outputing in base64, but is decoding the rows.
-
- 25 Mar, 2011 1 commit
-
-
Sven Sandberg authored
Problem: mysqlbinlog --server-id may filter out Format_description_log_events. If mysqlbinlog does not process the Format_description_log_event, then mysqlbinlog cannot read the rest of the binary log correctly. This can have the effect that mysqlbinlog crashes, generates an error, or generates output that causes mysqld to crash, generate an error, or corrupt data. Fix: Never filter out Format_description_log_events. Also, never filter out Rotate_log_events. client/mysqlbinlog.cc: Process Format_description_log_events even when the server_id does not match the number given by --server-id. mysql-test/t/mysqlbinlog.test: Add test case.
-
- 16 Jan, 2011 1 commit
-
-
Nirbhay Choubey authored
command line clients. Postfix covering other mysql standard clients like mysql_upgrade, mysqlbinlog, mysqlcheck, mysqlimport, mysqlshow and mysqlslap. client/client_priv.h: Bug#58139 : default-auth option not recognized in MySQL standard command line clients Added an entry for 'default-auth' option. client/mysql.cc: Bug#58139 : default-auth option not recognized in MySQL standard command line clients Updated the id entry for default_auth option. client/mysql_upgrade.c: Bug#58139 : default-auth option not recognized in MySQL standard command line clients. Introduced two new variables to hold values from default-auth and plugin-dir options and further pushed them to client's st_mysql instance. client/mysqladmin.cc: Bug#58139 : default-auth option not recognized in MySQL standard command line clients Updated the id entry for default_auth option. client/mysqlbinlog.cc: Bug#58139 : default-auth option not recognized in MySQL standard command line clients. Introduced two new variables to hold values from default-auth and plugin-dir options and further pushed them to client's st_mysql instance. client/mysqlcheck.c: Bug#58139 : default-auth option not recognized in MySQL standard command line clients. Introduced two new variables to hold values from default-auth and plugin-dir options and further pushed them to client's st_mysql instance. client/mysqldump.c: Bug#58139 : default-auth option not recognized in MySQL standard command line clients Updated the id entry for default_auth option. client/mysqlimport.c: Bug#58139 : default-auth option not recognized in MySQL standard command line clients. Introduced two new variables to hold values from default-auth and plugin-dir options and further pushed them to client's st_mysql instance. client/mysqlshow.c: Bug#58139 : default-auth option not recognized in MySQL standard command line clients. Introduced two new variables to hold values from default-auth and plugin-dir options and further pushed them to client's st_mysql instance. client/mysqlslap.c: Bug#58139 : default-auth option not recognized in MySQL standard command line clients. Introduced two new variables to hold values from default-auth and plugin-dir options and further pushed them to client's st_mysql instance. mysql-test/r/plugin_auth.result: Added test case for Bug#58139 for mysql_upgrade. mysql-test/t/plugin_auth.test: Added test case for Bug#58139 for mysql_upgrade.
-
- 29 Oct, 2010 1 commit
-
-
Sven Sandberg authored
Adds deprecation warning for the mysqlbinlog options --base64-output=always and --base64-output. A warning is printed when the flags are used, and also when running mysqlbinlog --help. client/mysqlbinlog.cc: Give a warning for --base64-output=always and --base64-output, and print warning in mysqlbinlog --help. mysql-test/r/mysqlbinlog.result: updated result file mysql-test/t/mysqlbinlog.test: Test that mysqlbinlog --base64-output=always gives a warning.
-
- 06 Oct, 2010 1 commit
-
-
Alexander Nozdrin authored
The fix is to: - introduce ORACLE_WELCOME_COPYRIGHT_NOTICE define to have a single place to specify copyright notice; - replace custom copyright notices with ORACLE_WELCOME_COPYRIGHT_NOTICE in programs.
-
- 15 Jul, 2010 1 commit
-
-
Davi Arnaut authored
Remove Netware specific code.
-
- 09 Jul, 2010 1 commit
-
-
Davi Arnaut authored
Although the C standard mandates that sprintf return the number of bytes written, some very ancient systems (i.e. SunOS 4) returned a pointer to the buffer instead. Since these systems are not supported anymore and are hopefully long dead by now, simply remove the portability wrapper that dealt with this discrepancy. The autoconf check was causing trouble with GCC.
-
- 08 Jul, 2010 3 commits
-
-
Luis Soares authored
The server was not cleaning up some dbug allocated memory before exiting. This is not a real problem, as this memory would be deallocated anyway. Nonetheless, we improve the mysqlbinlog exit procedure, wrt to memory book-keeping, when no parameter is given. To fix this, we deploy a call to my_end() before the thread exits.
-
Davi Arnaut authored
Essentially, the problem is that safemalloc is excruciatingly slow as it checks all allocated blocks for overrun at each memory management primitive, yielding a almost exponential slowdown for the memory management functions (malloc, realloc, free). The overrun check basically consists of verifying some bytes of a block for certain magic keys, which catches some simple forms of overrun. Another minor problem is violation of aliasing rules and that its own internal list of blocks is prone to corruption. Another issue with safemalloc is rather the maintenance cost as the tool has a significant impact on the server code. Given the magnitude of memory debuggers available nowadays, especially those that are provided with the platform malloc implementation, maintenance of a in-house and largely obsolete memory debugger becomes a burden that is not worth the effort due to its slowness and lack of support for detecting more common forms of heap corruption. Since there are third-party tools that can provide the same functionality at a lower or comparable performance cost, the solution is to simply remove safemalloc. Third-party tools can provide the same functionality at a lower or comparable performance cost. The removal of safemalloc also allows a simplification of the malloc wrappers, removing quite a bit of kludge: redefinition of my_malloc, my_free and the removal of the unused second argument of my_free. Since free() always check whether the supplied pointer is null, redudant checks are also removed. Also, this patch adds unit testing for my_malloc and moves my_realloc implementation into the same file as the other memory allocation primitives. client/mysqldump.c: Pass my_free directly as its signature is compatible with the callback type -- which wasn't the case for free_table_ent.
-
Luis Soares authored
-
- 06 Jul, 2010 1 commit
-
-
Luis Soares authored
The server was not cleaning up dbug allocated memory before exiting. This is not a real problem, as this memory would be deallocated anyway. Nonetheless, we improve the mysqlbinlog exit procedure, wrt to memory book-keeping, when no parameter is given. To fix this, we deploy a call to my_thread_end() before the thread exits, which will also free pending dbug related allocated blocks.
-
- 10 Jun, 2010 1 commit
-
-
Davi Arnaut authored
strict aliasing violations. Essentially, the problem is that large parts of the server were developed in simpler times (last decades, pre C99 standard) when strict aliasing and compilers supporting such optimizations were rare to non-existent. Thus, when compiling the server with a modern compiler that uses strict aliasing rules to perform optimizations, there are several places in the code that might trigger undefined behavior. As evinced by some recent bugs, GCC does a somewhat good of job misoptimizing such code, but on the other hand also gives warnings about suspicious code. One problem is that the warnings aren't always accurate, yet we can't afford to just shut them off as we might miss real cases. False-positive cases are aggravated mostly by casts that are likely to trigger undefined behavior. The solution is to start a cleanup process focused on fixing and reducing the amount of strict-aliasing related warnings produced by GCC and others compilers. A good deal of noise reduction can be achieved by just removing useless casts that are product of historical cruft and are likely to trigger undefined behavior if dereferenced. client/mysql.cc: Remove now-unnecessary casts. Break up large strings. client/mysql_upgrade.c: Remove now-unnecessary casts. client/mysqladmin.cc: Remove now-unnecessary casts. Break up large strings. client/mysqlbinlog.cc: Remove now-unnecessary casts. client/mysqlcheck.c: Remove now-unnecessary casts. client/mysqldump.c: Remove now-unnecessary casts. client/mysqlimport.c: Remove now-unnecessary casts. client/mysqlshow.c: Remove now-unnecessary casts. client/mysqlslap.c: Remove now-unnecessary casts. client/mysqltest.cc: Remove now-unnecessary casts. extra/comp_err.c: Remove now-unnecessary casts. extra/my_print_defaults.c: Remove now-unnecessary casts. Break up large strings. extra/mysql_waitpid.c: Remove now-unnecessary casts. extra/perror.c: Remove now-unnecessary casts. extra/resolve_stack_dump.c: Remove now-unnecessary casts. extra/resolveip.c: Remove now-unnecessary casts. include/my_getopt.h: Use a void pointer type as the opaque type to avoid problems with type incompatibility -- GCC issues warnings when the type name is not type compatible with a operand. As a side bonus, a explicit cast won't be necessary anymore. include/sslopt-longopts.h: Remove now-unnecessary casts. Break up large strings. mysys/my_getopt.c: Update opaque type and introduce a type definition for the argument to my_getopt_register_get_addr. server-tools/instance-manager/options.cc: Remove now-unnecessary casts. sql/mysqld.cc: Remove now-unnecessary casts. Break up large strings. Update mysql_getopt_value prototype (the old prototype was different from the definition anyway). sql/sql_plugin.cc: The type of a pointer to a function must be compatible with the pointed-to function type, otherwise the behavior is undefined. sql/table.cc: The variable buf pointer to pointer to pointer to constant char could improperly alias a incompatible type in call to fix_type_ pointers. Since this was actually dead code, it is simply removed. sql/unireg.cc: Remove call to get_form_pos. The code creates a new FRM file which is always truncated and writes the form position as 0. Hence, no need to retrieve it, we now for sure it is 0. storage/archive/archive_reader.c: Remove now-unnecessary casts. storage/myisam/ft_nlq_search.c: Read weight directly from the buffer. storage/myisam/fulltext.h: Add explanation about the type duality of a key buffer. Add accessor macro to retrieve a FT float value. storage/myisam/mi_test1.c: Remove now-unnecessary casts. storage/myisam/myisam_ftdump.c: Read weight directly from the buffer. storage/myisam/myisamchk.c: Remove now-unnecessary casts. storage/myisam/myisamlog.c: A pointer to char was used to alias a pointer to pointer to unsigned char, thus violating strict aliasing rules. storage/myisam/myisampack.c: Remove now-unnecessary casts. strings/decimal.c: Remove aliasing violation, printing the value is enough for debugging purposes. tests/mysql_client_test.c: Remove now-unnecessary casts.
-
- 31 Mar, 2010 1 commit
-
-
Mats Kindahl authored
This patch: - Moves all definitions from the mysql_priv.h file into header files for the component where the variable is defined - Creates header files if the component lacks one - Eliminates all include directives from mysql_priv.h - Eliminates all circular include cycles - Rename time.cc to sql_time.cc - Rename mysql_priv.h to sql_priv.h
-
- 28 Mar, 2010 1 commit
-
-
unknown authored
When mysqlbinlog was given the --database=X flag, it always printed 'ROLLBACK TO', but the corresponding 'SAVEPOINT' statement was not printed. The replicated filter(replicated-do/ignore-db) and binlog filter (binlog-do/ignore-db) has the same problem. They are solved in this patch together. After this patch, We always check whether the query is 'SAVEPOINT' statement or not. Because this is a literal check, 'SAVEPOINT' and 'ROLLBACK TO' statements are also binlogged in uppercase with no any comments. The binlog before this patch can be handled correctly except one case that any comments are in front of the keywords. for example: /* bla bla */ SAVEPOINT a; /* bla bla */ ROLLBACK TO a;
-
- 17 Feb, 2010 2 commits
-
-
Luis Soares authored
I found three issues during the analysis: 1. Memory leak caused by temp_buf not being freed; 2. Memory leak caused when handling argv; 3. Conditional jump that depended on unitialized values. Issue #1 -------- DESCRIPTION: when mysqlbinlog is reading from a remote location the event temp_buf references the incoming stream (in NET object), which is not freed by mysqlbinlog explicitly. On the other hand, when it is reading local binary log, it points to a temporary buffer that needs to be explicitly freed. For both cases, the temp_buf was not freed by mysqlbinlog, instead was set to 0. This clearly disregards the free required in the second case, thence creating a memory leak. FIX: we make temp_buf to be conditionally freed depending on the value of remote_opt. Found out that similar fix is already in most recent codebases. Issue #2 -------- DESCRIPTION: load_defaults is called by parse_args, and it reads default options from configuration files and put them BEFORE the arguments that are already in argc and argv. This is done resorting to MEM_ROOT. However, parse_args calls handle_options immediately after which changes argv. Later when freeing the defaults, pointers to MEM_ROOT won't match, causing the memory not to be freed: void free_defaults(char **argv) { MEM_ROOT ptr memcpy_fixed((char*) &ptr,(char *) argv - sizeof(ptr), sizeof(ptr)); free_root(&ptr,MYF(0)); } FIX: we remove load_defaults from parse_args and call it before. Then we save argv with defaults in defaults_argv BEFORE calling parse_args (which inside can then call handle_options at will). Actually, found out that this is in fact kind of a backport for BUG#38468 into 5.1, so I merged in the test case as well and added error check for load_defaults call. Fix based on: revid:zhenxing.he@sun.com-20091002081840-uv26f0flw4uvo33y Issue #3 -------- DESCRIPTION: the structure st_print_event_info constructor would not initialize the sql_mode member, although it did for sql_mode_inited (set to false). This would later raise the warning in valgrind when printing the sql_mode in the event header, as this print out is protected by a check against sql_mode_inited and sql_mode variables. Given that sql_mode was not initialized valgrind would output the warning. FIX: we add initialization of sql_mode to the st_print_event_info constructor. client/mysqlbinlog.cc: - Conditionally free ev->temp_buf. - save defaults_argv before handle_options is called. mysql-test/t/mysqlbinlog.test: Added test case from BUG#38468. sql/log_event.cc: Added initialization of sql_mode for st_print_event_info.
-
Magne Mahre authored
A set of program options and variables was deprecated in MySQL 5.1, and is hereby removed. client/mysql.cc: --no-auto-rehash (-A) is no longer deprecated --no-named-commands (-g) is now removed --skip-line-numbers (-L) is no longer deprecated --set-variable (-O) is now removed --no-pager is now removed client/mysqlbinlog.cc: --position is now removed (use --start-position) -j is now equivalent with --start-position client/mysqldump.c: --first-slave is now removed --no-set-names (-N) is now removed --set-variable (-O) is now removed mysql-test/include/default_mysqld.cnf: default-character-set is removed as an option character-set-server is equivalent. mysql-test/t/bug47671-master.opt: default-character-set option is removed character-set-server is equivalent mysql-test/t/ctype_latin1_de-master.opt: default-character-set option is removed character-set-server is equivalent mysql-test/t/ctype_ucs2_def-master.opt: default-collation is removed collation-server is equicalent scripts/mysqld_multi.sh: --config-file has been superseded by --defaults-extra-file sql/mysql_priv.h: Removed the version number in the deprecation warning text, as decided by ServerPT. sql/mysqld.cc: --default-character-set (-C) is removed --default-collation is removed --log-long-format (-0) is removed --safe-show-database is removed --set-variable (-O) is removed sql/sql_yacc.yy: The FRAC_SECOND keyword is removed sql/sys_vars.cc: The sql_log_update system variable is removed
-
- 21 Jan, 2010 1 commit
-
-
Magne Mahre authored
Several items said to be deprecated in the 4.1 manual have never been removed. This worklog adds deprecation warnings when these items are used, and warns the user that the items will be removed in MySQL 5.6. A couple of previously deprecation decision have been reversed (see single file comments) client/client_priv.h: Macro similar to the one in the server (mysql_priv.h) for printing a deprecation warning message client/mysql.cc: no-auto-rehash will not be deprecated skip-line-numbers will not be deprecated skip-column-names will not be deprecated no-pager is deprecated set-variable is deprecated no-named-commands is deprecated client/mysqladmin.cc: set-variable is deprecated client/mysqlbinlog.cc: position is deprecated client/mysqldump.c: first-slave is deprecated no-set-names is deprecated set-variable is deprecated mysql-test/r/mysqlbinlog.result: Adding the [Warning] to the test case, just to show that the deprecation works. The test case will be changed in Celosia to use --start-position. mysys/my_getopt.c: set-variable (include -O) is deprecated scripts/mysqld_multi.sh: Warning for mysqld_multi sql/mysqld.cc: default-collation is deprecated log-bin-trust-routine-creators is deprecated set-variable is deprecated default-character-set is deprecated safe-show-database is deprecated sql/share/errmsg.txt: Added version number for sql_log_update deprecation message.
-
- 04 Feb, 2010 1 commit
-
-
Staale Smedseng authored
-
- 14 Dec, 2009 1 commit
-
-
Mats Kindahl authored
Row-based replication requires the types of columns on the master and slave to be approximately the same (some safe conversions between strings are allowed), but does not allow safe conversions between fields of similar types such as TINYINT and INT. This patch implement type conversions between similar fields on the master and slave. The conversions are controlled using a new variable SLAVE_TYPE_CONVERSIONS of type SET('ALL_LOSSY','ALL_NON_LOSSY'). Non-lossy conversions are any conversions that do not run the risk of losing any information, while lossy conversions can potentially truncate the value. The column definitions are checked to decide if the conversion is acceptable. If neither conversion is enabled, it is required that the definitions of the columns are identical on master and slave. Conversion is done by creating an internal conversion table, unpacking the master data into it, and then copy the data to the real table on the slave. .bzrignore: New files added client/Makefile.am: New files added client/mysqlbinlog.cc: Functions in rpl_utility.cc is now needed by mysqlbinlog.cc. libmysqld/Makefile.am: New files added mysql-test/extra/rpl_tests/check_type.inc: Test include file to check a single type conversion. mysql-test/extra/rpl_tests/rpl_extraSlave_Col.test: Switching to use INT instead of TEXT for column that should not have matching types. mysql-test/extra/rpl_tests/rpl_row_basic.test: Adding code to enable type conversions for BIT tests since InnoDB cannot handle them properly due to incorrect information stored as metadata. mysql-test/extra/rpl_tests/type_conversions.test: Test file to check a set of type conversions with current settings of slave_type_conversions. mysql-test/suite/rpl/t/rpl_typeconv.test: Test file to test conversions from master to slave with all possible values for slave_type_conversions. The test also checks that the slave_type_conversions variable works as expected. sql/field.cc: Changing definition of compatible_field_size to both check if two field with identical base types are compatible and give an order between them if they are compatible. This only implement checking on the slave, so it will not affect replication from an old master to a new slave. sql/field.h: Changing prototypes for functions: - compatible_field_size() - init_for_tmp_table() - row_pack_length() sql/log_event.cc: Changing compability checks to build a conversion table if the fields are compatible, but does not have the same base type. sql/log_event_old.cc: Changing compability checks to build a conversion table if the fields are compatible, but does not have the same base type. sql/mysql_priv.h: Adding global option variable for SLAVE_TYPE_CONVERSIONS sql/mysqld.cc: Adding SLAVE_TYPE_CONVERSIONS global server variable. sql/rpl_record.cc: Changing unpack_row to use the conversion table if present. sql/rpl_rli.h: Removing function get_tabledef and replacing it with get_table_data(). This function retrieve data for table opened for replication, not just table definition. sql/rpl_utility.cc: Function table_def::compatible_with is changed to compare table on master and slave for compatibility and generate a conversions table if they are compatible. Computing real type of fields from metadata for ENUM and SET types. Computing pack_length correctly for ENUM, SET, and BLOB types. Adding optimization to not check compatibility if no slave type conversions are enabled. sql/rpl_utility.h: Changing prototypes since implementation has changed. Modifying table_def::type() to return real type instead of stored type. sql/set_var.cc: Adding SLAVE_TYPE_CONVERSIONS variable. sql/set_var.h: Adding SLAVE_TYPE_CONVERSIONS variable. sql/share/errmsg.txt: Adding error messages for slave type conversions. sql/sql_class.h: Adding SLAVE_TYPE_CONVERSIONS variable. sql/sql_select.cc: Correcting create_virtual_tmp_table() to compute null bit positions correctly in the presence of bit fields.
-
- 20 Nov, 2009 1 commit
-
-
Andrei Elkin authored
The mentioned on the bug report set of bugs fixes have not be pushed to the main trees. Fixed with extracting commits done to 6.0-rpl tree and applying them to the main 5.1. Notes. 1. part of changes - the mtr's specific - were packported to the main 5.0 tree for mtr v1 as http://lists.mysql.com/commits/46562 However, there is no that fix anymore in the mtr v2. (This fact was mailed to mtr maintaining people). 2. Bug@36929 crash in kill_zombie_dump_threads-> THD::awake() with replication tests is not backported because the base code of the patch is libevent and that was removed from the main trees due to its instability. client/mysqlbinlog.cc: fixes for BUG#35546 mysql-test/suite/rpl/r/rpl_bug41902.result: the new tests result file is added. mysql-test/suite/rpl/t/rpl_bug41902-slave.opt: conf file for bug41902 testing is added. mysql-test/suite/rpl/t/rpl_bug41902.test: regression tests for Bug #41902 is added. sql/log.cc: collection of changes due to Bug #48463. sql/log.h: collection of changes due to Bug #48463. sql/rpl_rli.h: collection of changes due to Bug #48463. sql/slave.cc: collection of changes due to Bug #48463. sql/sql_repl.cc: collection of changes due to Bug #48463.
-
- 03 Nov, 2009 1 commit
-
-
Vladislav Vaintroub authored
The reason for the bug is that mysqtest as well as other client tools running in test suite (mysqlbinlog, mysqldump) will first try to connect whatever database has created shared memory with default base name "MySQL" and use this. (Same effect could be seen on Unix if mtr would not care to calculate "port" and "socket" parameter). The fix ensures that all client tools and running in mtr use unique per-database shared memory base parameters, so there is no possibility to clash with already installed one. We use socket name for shared memory base (it's known to be unique). This shared-memory-base is written to the MTR config file to the [client] and [mysqld] sections. Fix made also made sure all client tools understand and correctly handle --shared-memory-base. Prior to this patch it was not the case for mysqltest, mysqlbinlog and mysql_client_test. All new connections done from mtr scripts via connect() will by default set shared-memory-base. And finally, there is a possibility to force shared memory or pipe connection and overwrite shared memory/pipe base name from within mtr scripts via optional PIPE or SHM modifier. This functionality was manually backported from 6.0 (original patch http://lists.mysql.com/commits/74749)
-
- 28 Oct, 2009 1 commit
-
-
unknown authored
Append the description of the 'decode-rows' value for --base64-output argument.
-
- 20 Oct, 2009 1 commit
-
-
unknown authored
There are some problems about help text: - It is stated that "auto" is the default twice. It need be stated only once. - It is stated that --base64-output is short for --base64-output=always. But that sounds like the default is "always", not "auto". Make the help text clear as following: Determine when the output statements should be base64-encoded BINLOG statements: 'never' disables it and works only for binlogs without row-based events; 'auto' prints base64 only when necessary (i.e., for row-based events and format description events); 'always' prints base64 whenever possible. 'always' is for debugging only and should not be used in a production system. If this argument is not given, the default is 'auto'; if it is given with no argument, 'always' is used.
-
- 09 Oct, 2009 1 commit
-
-
Alexey Botchkov authored
added code to exit a tool if the forced config file wasn't found per-file comments: client/mysql.cc Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found client/mysql_upgrade.c Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found client/mysqladmin.cc Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found client/mysqlcheck.c Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found client/mysqldump.c Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found client/mysqlimport.c Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found client/mysqlshow.c Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found client/mysqlslap.c Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found mysql-test/t/mysql.test Bug#47216 programs should quit if the file specified by --defaults-file option isn't found test added sql/mysqld.cc Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found storage/myisam/myisamchk.c Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found storage/myisam/myisampack.c Bug#47216 programs should quit if the file specified by --defaults-file option isn't found added code to exit a tool if the forced config file wasn't found
-
- 02 Oct, 2009 1 commit
-
-
He Zhenxing authored
There were two memory leaks in mysqlbinlog command, one was already fixed by previous patches, another one was that defaults_argv was set to the value of argv after parse_args, in which called handle_options after calling load_defaults and changed the value of argv, and caused the memory allocated for defaults arguments not freed. Fixed the problem by setting defaults_argv right after calling load_defaults.
-
- 30 Sep, 2009 1 commit
-
-
unknown authored
The 'BEGIN/COMMIT/ROLLBACK' log event could be filtered out if the database is not selected by --database option of mysqlbinlog command. This can result in problem if there are some statements in the transaction are not filtered out. To fix the problem, mysqlbinlog will output 'BEGIN/ROLLBACK/COMMIT' in regardless of the database filtering rules. client/mysqlbinlog.cc: Skip the database check for BEGIN/COMMIT/ROLLBACK log events. mysql-test/r/mysqlbinlog.result: Test result for bug#46998 mysql-test/t/mysqlbinlog.test: Added test to verify if the 'BEGIN', 'COMMIT' and 'ROLLBACK' are output in regardless of database filtering
-
- 11 Sep, 2009 1 commit
-
-
Vladislav Vaintroub authored
Bug#24509 - 2048 file descriptor limit on windows needs increasing, also WL#3049 - improved Windows I/O The patch replaces the use of the POSIX I/O interfaces in mysys on Windows with the Win32 API calls (CreateFile, WriteFile, etc). The Windows HANDLE for the open file is stored in the my_file_info struct, along with a flag for append mode because the Windows API does not support opening files in append mode in all cases) The default max open files has been increased to 16384 and can be increased further by setting --max-open-files=<value> during the server start. Another major change in this patch that almost all Windows specific file IO code has been moved to a new file my_winfile.c, greatly reducing the amount of code in #ifdef blocks within mysys, thus improving readability. Minor enhancements: - my_(f)stat() is changed to use __stati64 structure with 64 file size and timestamps. It will return correct file size now (C runtime implementation used to report outdated information) - my_lock on Windows is prepared to handle additional timeout parameter - after review : changed __WIN__ to _WIN32 in the new and changed code. client/mysqlbinlog.cc: fileno -> my_fileno client/readline.cc: fileno -> my_fileno include/config-win.h: Increase OS_FILE_LIMIT for Windows. Remove O_SHARE - Windows does not support it. Its definition conflicts with O_SHORT_LIVED, that has different semantics. include/my_dir.h: Use stat64 for stat() family of functions on Windows, because of 64 bit file size. include/my_global.h: Increased default value for open file limit to 16K include/my_sys.h: - my_file_info got new structure members - file handle and open flags - 2 new Windows-only mysys functions : my_get_osfhandle and my_osmaperr, modelled after Windows C runtime functions _get_osfhandle and _dosmaperr libmysql/CMakeLists.txt: new files my_winfile.c and my_winerr.c mysql-test/suite/large_tests/r/lock_tables_big.result: test for more then 2048 open file descriptors on Windows mysql-test/suite/large_tests/t/lock_tables_big.test: test for more then 2048 open file descriptors on Windows mysys/CMakeLists.txt: new files my_winfile.c and my_winerr.c mysys/Makefile.am: new files my_winfile.c and my_winerr.c mysys/default_modify.c: fileno -> my_fileno mysys/my_chsize.c: implementation of chsize on Windows now moved to my_winfile.c mysys/my_create.c: - my_sopen->my_win_open - close open file before removing (won't generally work on Windows otherwise) mysys/my_file.c: On Windows, files returned by my_open will not start with 0, but 2048 (making it simple to detect incompatible mix of CRT and mysys io functions) mysys/my_fopen.c: fileno->my_win_fileno , fclose->my_win_fclose, fdopen->my_win_fdopen Check for legal filename is done by my_win_[f]open functions mysys/my_fstream.c: fileno->my_fileno mysys/my_lib.c: Windows stat() functions are moved to my_winfile.c mysys/my_lock.c: Move Windows code under #ifdef to a separate function win_lock(). Add a parameter for lock wait timeout mysys/my_mmap.c: _get_osfhandle->my_get_osfhandle mysys/my_open.c: my_sopen->my_win_open (simpler interface) mysys/my_pread.c: moved most windows specific code to my_win_file.c Use my_win_pread mysys/my_quick.c: Use my_win_read/my_win_write mysys/my_read.c: Moved most of windows specific code to my_win_file.c Use my_win_read() mysys/my_seek.c: On Windows, use my_win_lseek() in my_seek()/my_tell() Removed dead code (synchronization of lseeks) Improved DBUG tracing (file position is ulonglong, not ulong) mysys/my_static.c: Removed array initialization. my_file_info_default is global variable thus it is initialized with all zeros anyway mysys/my_sync.c: _commit->my_win_fsync mysys/my_winerr.c: New file my_winerr.c Exports my_osmaperr modelled after undocumented C runtime function _dosmaperr(). The problem with _dosmaperr() used previously is that 1) it is nowhere documented and thus code relying on it is not guaranteed to work in subsequent releases on the C runtime 2) it is present only in static C runtime (mysqld does not link if compiled with /MD) mysys/my_winfile.c: New file my_winfile.c Implements ANSI/Posix file IO routines, when possible using native Windows IO, without C runtime (C runtime dropped because of the 2048 file descriptor limit). mysys/my_write.c: write->my_win_write mysys/mysys_priv.h: Declaration of Windows Posix functions (private to mysys, shall not be visible outside) storage/innobase/handler/ha_innodb.cc: mysys native Windows IO : correct innodb tmp file handling mysql_tmpfile does not return valid CRT file descriptor, thus it is not possible to dup() it. Instead, the native file handle has to be duplicated and then converted to CRT descriptor. storage/myisam/mi_locking.c: _commit->my_sync
-
- 29 Jun, 2009 1 commit
-
-
Staale Smedseng authored
-
- 07 Jun, 2009 1 commit
-
-
Luis Soares authored
mysqlbinlog --database parameter was being ignored when processing row events. As such no event filtering would take place. This patch addresses this by deploying a call to shall_skip_database when table_map_events are handled (as these contain also the name of the database). All other rows events referencing the table id for the filtered map event, will also be skipped. client/mysqlbinlog.cc: Added shall_skip_database call to the part of the code that handles Table_map_log_events. It inspects the database name and decides whether to filter the event or not. Furthermore, if table map event is filtered next events referencing the table id in the table map event, will also be filtered. mysql-test/suite/binlog/t/binlog_row_mysqlbinlog_db_filter.test: Test case that checks if row events are actually filtered out. sql/log_event.h: Added a map for holding the currently ignored table map events. Table map events are inserted when they shall be skipped and removed once the last row event in the statement is processed.
-
- 15 May, 2009 2 commits
-
-
Jim Winstead authored
intentionally unmentioned (it is just a placeholder). (Bug #41403)
-
Jim Winstead authored
are supported. (Bug #42021)
-
- 07 May, 2009 2 commits
-
-
Jim Winstead authored
handle the --skip-password option correctly. (Bug #28479)
-
Alexey Kopytov authored
The --hexdump option crashed mysqlbinlog when used together with the --read-from-remote-server option due to use of uninitialized memory. Since Log_event::print_header() relies on temp_buf to be initialized when the --hexdump option is present, dump_remote_log_entries() was fixed to setup temp_buf to point to the start of a binlog event as done in dump_local_log_entries(). The root cause of this bug is identical to the one for bug #17654. The latter was fixed in 5.1 and up, so this patch is backport of the patches for bug #17654 to 5.0. Only 5.0 needs a changelog entry. client/mysqlbinlog.cc: Fixed dump_remote_log_entries() so that temp_buf is initialized as it may be used later by Log_event::print_header() if the --hexdump option is present. mysql-test/r/mysqlbinlog.result: Added a test case for bug #41943. mysql-test/t/mysqlbinlog.test: Added a test case for bug #41943.
-
- 10 Feb, 2009 1 commit
-
-
Ignacio Galarza authored
- Remove bothersome warning messages. This change focuses on the warnings that are covered by the ignore file: support-files/compiler_warnings.supp. - Strings are guaranteed to be max uint in length
-
- 21 Aug, 2008 1 commit
-
-
Alexander Barkov authored
- Implementing --base64-format=decode-rows, to display SQL-alike decoded row events without their BINLOG statements. - Adding --base64-format=decode-rows into tests when calling mysqlbinlog to avoid non-deterministic results - Removing resetting of last_table_id in "RESET MASTER", which appeared to be dangerous.
-