1. 23 Sep, 2010 3 commits
    • Michael Widenius's avatar
    • Michael Widenius's avatar
      Change some my_bool in C++ classes and a few functions to bool to detect wrong... · ae0a36dd
      Michael Widenius authored
      Change some my_bool in C++ classes and a few functions to bool to detect wrong usage of bool/my_bool.
      Fix some bugs where we stored values other than 0 or 1 in my_bool
      Fixed some compiler warnings
      
      
      client/mysql.cc:
        Changed interrupted_query from my_bool to int, as we stored 2 in it.
      client/mysqladmin.cc:
        Changed return variable type to same type as function value type
      client/mysqltest.cc:
        Changed 'found' to int as we store other values than 0 or 1 into it
        Changed type for parameter of set_reconnect() to match usage.
      extra/libevent/evbuffer.c:
        Added __attribute__((unused))
      extra/libevent/event.c:
        Added __attribute__((unused))
      extra/libevent/signal.c:
        Added __attribute__((unused))
      sql/event_data_objects.h:
        my_bool -> bool
      sql/event_db_repository.cc:
        my_bool -> bool
      sql/event_db_repository.h:
        my_bool -> bool
      sql/event_parse_data.h:
        my_bool -> bool
      sql/events.cc:
        my_bool -> bool
      sql/events.h:
        my_bool -> bool
      sql/field.cc:
        my_bool -> bool
      sql/field.h:
        my_bool -> bool
      sql/hash_filo.h:
        my_bool -> bool
      sql/item.cc:
        my_bool -> bool
      sql/item.h:
        my_bool -> bool
      sql/item_cmpfunc.h:
        my_bool -> bool
        Changed result_for_null_param from my_bool to int as we stored -1 in it.
      sql/item_func.cc:
        my_bool -> bool
        Modified udf wrapper functions so that the UDF functions would continue to use my_bool. (To keep compatibility with UDF:s)
      sql/item_func.h:
        my_bool -> bool
      sql/item_subselect.h:
        my_bool -> bool
      sql/item_sum.cc:
        Modified udf wrapper functions so that the UDF functions would continue to use my_bool. (To keep compatibility with UDF:s)
      sql/parse_file.h:
        my_bool -> bool
      sql/rpl_mi.h:
        my_bool -> bool
      sql/sp_rcontext.h:
        my_bool -> bool
      sql/sql_analyse.h:
        my_bool -> bool
      sql/sql_base.cc:
        Change some assignments so that we don't initialize bool variables with int's.
      sql/sql_bitmap.h:
        my_bool -> bool
      sql/sql_cache.cc:
        my_bool -> bool
      sql/sql_cache.h:
        my_bool -> bool
      sql/sql_class.h:
        my_bool -> bool
      sql/sql_insert.cc:
        Change some assignments so that we don't initialize bool variables with int's.
      sql/sql_prepare.cc:
        my_bool -> bool
      sql/table.h:
        my_bool -> bool
      storage/maria/ma_check.c:
        Removed duplicate assignment
      strings/decimal.c:
        Fixed wrong variable usage.
        Don't do complex arithmetic on bool when simple works.
      ae0a36dd
    • Michael Widenius's avatar
      Fix usage of mysqld option --new, --old, --safe and --skip_new to not disable... · ddfe2129
      Michael Widenius authored
      Fix usage of mysqld option --new, --old, --safe and --skip_new to not disable things that are proven stable or enable things that are not usefull.
      
      
      sql/field.cc:
        Remove feature of 'new_mode' that was never implemtented in a newer MySQL version.
      sql/item_cmpfunc.cc:
        Boyer more is stable; Don't have to be protected by --skip-new anymore
      sql/mysqld.cc:
        Don't disable some proven stable functions with --skip-new
      sql/records.cc:
        Don't disable record caching with --safe-mode anymore
      sql/sql_delete.cc:
        Do fast truncate even if --skip-new or --safe is used
      sql/sql_parse.cc:
        Use always mysql_optimizer() for optimizer (instead of mysql_recreate_table() in case of --safe or --skip-new)
      sql/sql_select.cc:
        Don't disable 'only_eq_ref_tables' if --safe is used.
      sql/sql_yacc.yy:
        Removed not meaningfull test of --old
      ddfe2129
  2. 26 Aug, 2010 1 commit
    • Michael Widenius's avatar
      Fixed compiler warnings · 2b5f744c
      Michael Widenius authored
      sql/item.h:
        Fixed wrong declaration
      storage/sphinx/ha_sphinx.h:
        Fixed arguments to read_time()
      storage/sphinx/snippets_udf.cc:
        Include mysql headerfile first to avoid compiler warnings
      2b5f744c
  3. 24 Aug, 2010 10 commits
    • Michael Widenius's avatar
      Automerge with 5.1 · 6f1caf29
      Michael Widenius authored
      6f1caf29
    • Michael Widenius's avatar
      Automerge with 5.1 · ac2f8f4d
      Michael Widenius authored
      ac2f8f4d
    • Michael Widenius's avatar
      Fixed typo in last push (sorry about that) · 2d4b921a
      Michael Widenius authored
      - Need to get autopush to work to avoid bad pushes like this....
      2d4b921a
    • Michael Widenius's avatar
      Fixed failing test · 951c4f87
      Michael Widenius authored
      Increased default buffers to speed up maria_chk
      
      mysql-test/suite/maria/r/maria3.result:
        Fixed failing test
      storage/maria/maria_chk.c:
        Increase default page_buffer_size
      storage/maria/maria_def.h:
        Increased default sort buffer size for maria_chk.
      951c4f87
    • Michael Widenius's avatar
      Automatic merge · 861d0c86
      Michael Widenius authored
      Fixed compiler warning
      
      client/mysql.cc:
        Fixed compiler warning
      include/my_global.h:
        Fixed typo
      storage/maria/ha_maria.cc:
        Merge
      861d0c86
    • Michael Widenius's avatar
      Increase some very old limits. · 5fbf323e
      Michael Widenius authored
      This will give a smoother experience when using the Aria engine by those that are using default limits
      without still causing a notable problem for desktop users.
      5fbf323e
    • Michael Widenius's avatar
      Automatic merge · 73f172f4
      Michael Widenius authored
      73f172f4
    • Michael Widenius's avatar
      Automatic merge with main 5.1 · 2eeb1b85
      Michael Widenius authored
      2eeb1b85
    • Michael Widenius's avatar
      Fix of LP#616253 Crash in _ma_bitmap_set_full_page_bits on Aria recovery · 7e292d6b
      Michael Widenius authored
      The bug was based on wrong undo data in recovery file and not enough checking of bad data.
      
      sql/sql_select.h:
        Added comment
      storage/maria/ma_blockrec.c:
        - Removed wrong sanity checks (didn't work for UNDO records)
        - More sanity checks and DBUG_ASSERT
        - More DBUG_ENTER and DBUG_PRINT
        - Removed filler blocks in extent_to_bitmap_blocks() as it caused problems in write_block_record().
          This was the main cause of the bug.
          (This change can make records generated by UNDO slightly smaller than original record, which we have to fix
          by correcting row_pos.length before calling write_block_record())
        - Fixed some problems in write_block_record() while doing UNDO.
        - Store header_length without TRANSID_SIZE into recovery log (as UNDO entires doesn't have TRANSID_SIZE)
        - Mark table crashed if something goes wrong during UNDO
      storage/maria/maria_def.h:
        Added header_length
      7e292d6b
    • Sergei Golubchik's avatar
      c8912ccf
  4. 23 Aug, 2010 2 commits
    • Michael Widenius's avatar
      Trivial fixes, more safe DBUG_ASSERT()'s and some more DBUG_ · 0bdc300d
      Michael Widenius authored
      - CTRL-C now aborts 'source' commands in mysql client
      - Fix that thread id's are removed in convert-debug-for-diff.sh
      
      
      client/mysql.cc:
        CTRL-C now aborts 'source' commands
      scripts/convert-debug-for-diff.sh:
        Fix expression to remove thread id
      storage/maria/ha_maria.cc:
        Don't call DBUG_ASSERT() when we kill a query during REPAIR / ALTER TABLE
      storage/maria/ma_bitmap.c:
        Added DBUG_ASSERT() if we call _ma_bitmap_set_full_page_bits()
      storage/maria/ma_key_recover.c:
        Don't do an assert if table is marked crashed.
      storage/maria/ma_recovery.c:
        Added DBUG_ENTER
      0bdc300d
    • Michael Widenius's avatar
      Fix for LP#612894 Some aggregate functions (such as MIN MAX) work incorrectly... · 21ae73cb
      Michael Widenius authored
      Fix for LP#612894 Some aggregate functions (such as MIN MAX) work incorrectly in subqueries after getting NULL value
      
      
      mysql-test/r/group_by.result:
        Added test that showed problems that no_rows_in_results() didn't work for expressions
      mysql-test/r/subselect4.result:
        Test case for LP#612894
      mysql-test/t/group_by.test:
        Added test that showed problems that no_rows_in_results() didn't work for expressions
      mysql-test/t/subselect4.test:
        Test case for LP#612894
      sql/item.h:
        Added restore_to_before_no_rows_in_result()
        Added function processor for no_rows_in_results() and restore_to_before_no_rows_in_results() to ensure it works with functions
        Fix that above functions are handled by Item_ref()
      sql/item_func.h:
        Ensure that no_rows_in_results() and restore_to_before_no_rows_in_result() are called for all function arguments
      sql/item_sum.cc:
        Added restore_to_before_no_rows_in_result() to restore settings after Item_sum_hybrid::no_rows_in_result() was called.
        This is needed to handle the case where we have made 'make_const()' on the item in opt_sum(), but the item will be reused again in a sub query.
        Ignore multiple calls to no_rows_in_result() as Item_ref is calling it twice.
      sql/item_sum.h:
        Added restore_to_before_no_rows_in_result();
      sql/sql_select.cc:
        Added reset of no_rows_in_result() for JOIN::reinit()
      sql/sql_select.h:
        Added marker if no_rows_in_result() is called.
      21ae73cb
  5. 20 Aug, 2010 3 commits
    • Michael Widenius's avatar
      Fixed compilation failure and added some new suppressions · 70c676f7
      Michael Widenius authored
      storage/maria/ma_blockrec.c:
        Fixed compilation failure
      support-files/compiler_warnings.supp:
        Added suppressions for pbxt
      70c676f7
    • Michael Widenius's avatar
    • Michael Widenius's avatar
      Fixed valgrind errors and compiler warnings discovered by buildbot · c1dd1ff9
      Michael Widenius authored
      More DBUG_ASSERT() to discover errors earlier
      More checking of BLOCK structures in Aria.
      Fixed crashing bug in Aria when doing UPDATE of several records in same block when doing table scan.
      
      storage/federatedx/ha_federatedx.cc:
        Added missing delete_dynamic(); This fixes the valgrind warnings about lost memory discovered by buildbot.
      storage/maria/ma_blockrec.c:
        Added debugging helper function _ma_print_block_info() to print block structure.
        Changed arguments to _ma_print_directory() so it can be called by _ma_print_block_info()
        check_directory() now also checks that empty_space on block is calculated correctly.
        Added some local variables to get more information about what happend when things crash.
        Fixed crashing bug when doing UPDATE of several records in same block when doing table scan.
      storage/maria/ma_key_recover.c:
        Simple optimization (don't call bmove_upp() if not needed); This could happen during page split.
      storage/maria/ma_recovery.c:
        Fixed compiler warning
      storage/maria/ma_test2.c:
        Run test without syncing to disk. (Not needed for this test)
      storage/maria/ma_write.c:
        More comments.
        Added DBUG_ASSERT() to find wrong log entires, like the one reported at LP#616344, during log file creation.
      storage/maria/unittest/ma_test_recovery.pl:
        Added extra -s to maria_chk to get it more silent.
        This fixes that ma_test_all.sh works again.
      c1dd1ff9
  6. 18 Aug, 2010 1 commit
    • Michael Widenius's avatar
      Added verbose mode to recovery · ca5c6534
      Michael Widenius authored
      More DBUG
      Added convert-debug-for-diff
      Added missing (from last push) federated test case
      
      .bzrignore:
        Ignore generated files
      mysql-test/README:
        Updated documentation for --extern
      mysql-test/suite/federated/federated_bug_32426.result:
        Added test for federatedx
      mysql-test/suite/federated/federated_bug_32426.test:
        Added test for federatedx
      scripts/Makefile.am:
        Added convert-debug-for-diff
      scripts/convert-debug-for-diff.sh:
        Added script for converting
      sql/log.cc:
        Added DBUG
      sql/mysqld.cc:
        Added DBUG
      storage/maria/ma_recovery.c:
        If verbose, write dirty pages (for debugging)
      storage/maria/ma_static.c:
        Added verbose mode to recovery
      storage/maria/maria_def.h:
        Added verbose mode to recovery
      storage/maria/maria_read_log.c:
        Added verbose mode to recovery
      ca5c6534
  7. 17 Aug, 2010 1 commit
    • Sergei Golubchik's avatar
      generalization of mtr to support suite.pm extensions: · dddf219d
      Sergei Golubchik authored
      * no automatic --loose-skip-innodb added by mtr based on the test name.
        instead loose-skip-innodb is now in the default_mysqld.cnf
      * have_innodb_plugin.inc is changed to give a verbose "skip" message
        (instead of "require: true")
      * My::Suite class. It's support in mtr, and everywhere
      * support for suite.pm
      * when sorting tests, take combinations into account
      * support for SUITENAME_COMBINATIONS
      * no special treatment for innodb_plugin in mtr_cases.pm
      * two special pre-created config groups: ENV and OPT
      * allow option names to start from #
      * allow magic option to have an argument
      * remove dead code
      * fix @-substitution to works as expected
      * new processes take the value of $opt_verbose automatically, no need to pass it to a constructor
      * innodb_plugin suite uses suite.pm and combinations file to test as much as possible
        (innodb plugin, xtradb plugin, xtradb static - whatever available)
      * besides test-master.opt and test-slave.opt a test.opt file is also
        loaded, both for master and slave
      * .opt files for all included files are loaded too
      * progress report in the xterm titlebar
      dddf219d
  8. 14 Aug, 2010 1 commit
  9. 12 Aug, 2010 3 commits
  10. 11 Aug, 2010 2 commits
    • Michael Widenius's avatar
    • Michael Widenius's avatar
      Fixed compiler warnings from Windows compiler · cf06da86
      Michael Widenius authored
      client/mysqlcheck.c:
        Added missing casts
      client/mysqldump.c:
        Added missing casts
      client/mysqlimport.c:
        Added missing casts
      extra/my_print_defaults.c:
        Added missing casts
      mysql-test/mysql-test-run.pl:
        Added suppression for non-critical warning on windows
      storage/maria/maria_pack.c:
        Added missing casts
      storage/xtradb/buf/buf0lru.c:
        Added missing casts
      storage/xtradb/fil/fil0fil.c:
        Added missing casts
      storage/xtradb/handler/i_s.cc:
        Added extra argument to call store() function for longlong.
      storage/xtradb/srv/srv0srv.c:
        Added cast to suppress compiler warning
      support-files/compiler_warnings.supp:
        Added suppression for some non critical compiler warnings on Windows
      unittest/mytap/tap.h:
        Fixed prototypes to be same as the actual functions
      cf06da86
  11. 10 Aug, 2010 6 commits
  12. 09 Aug, 2010 5 commits
    • Michael Widenius's avatar
      Automatic merge · 3845c502
      Michael Widenius authored
      3845c502
    • Michael Widenius's avatar
    • Michael Widenius's avatar
      Merge with 5.2 · 270f6664
      Michael Widenius authored
      Fixed some compiler errors regarding longlong2str()
      
      strings/longlong2str.c:
        Fixed usage of wrong variable
      strings/longlong2str_asm.c:
        Fixed wrong prototype
      270f6664
    • Michael Widenius's avatar
      Added --sync-sys=0 option for mysqld to skip sync() calls for faster testing · 62b9b884
      Michael Widenius authored
      Fixed LP#613418 (M)aria recovery failure: ma_key_recover.c:981: _ma_apply_redo_index: Assertion `check_page_length == page_length' failed
      
      include/my_sys.h:
        Added my_disable_sync
      mysql-test/mysql-test-run.pl:
        Added --sync-sys=0 to run test suite faster
      mysys/my_static.c:
        Added my_disable_sync
      mysys/my_sync.c:
        Added my_disable_sync
      sql/mysqld.cc:
        Added -sync-sys=0 option for mysqld to skip sync() calls for faster testing
      storage/maria/ma_key_recover.c:
        More DBUG_ASSERT()
        Added logging of KEY_OP_DEBUG to make examening of logs easier
        Fixed testing of page length in recovery to ensure we don't overwrite checksum (previous tests was too relaxed)
        Fixed bug in recovery logging of split pages which caused failure during recovery:
        - Length was not adjusted properly for pages to be split
        - Added KEY_OP_MAX_PAGELENGTH to tell recovery that page is now full length
        - This fixed LP#613418
      storage/maria/ma_key_recover.h:
        Changed prototype for ma_log_change() for KEY_OP_DEBUG
      storage/maria/ma_loghandler.h:
        Added new enums for better debugging of recovery logs
      storage/maria/ma_rt_index.c:
        Added debugging information to calls to ma_log_change()
      storage/maria/ma_write.c:
        Added debugging information to calls to ma_log_change() and ma_log_split()
      62b9b884
    • unknown's avatar
      Fix of soft group commit (assigned LSN instead of file number). Found by Monty. · e0e9998a
      unknown authored
      storage/maria/ma_loghandler.c:
        Fix of soft group commit (assigned LSN instead of file number).
      e0e9998a
  13. 07 Aug, 2010 2 commits