1. 21 Jan, 2008 2 commits
    • unknown's avatar
      fix for compiler warning · fd74a0da
      unknown authored
      
      sql/sql_table.cc:
        initialize variables used in 'err:' before going to err.
      fd74a0da
    • unknown's avatar
      An assertion added (transaction must be re-enabled before end of · d66157e3
      unknown authored
      top-level statement) and fixes for the bugs it finds.
      Fix for non-serious Valgrind warning.
      
      
      sql/sql_insert.cc:
        When CREATE TABLE IF NOT EXISTS finds the table already exists,
        'table' is the existing table. So if that table is temporary we don't
        re-enable transactions which is a bug.
      sql/sql_parse.cc:
        verify that at the end of each top-statement transactions have
        been re-enabled. Does not apply to substatements (consider
        CREATE TABLE t1 SELECT stored_func() : the substatements inside
        stored_func() run with transaction disabled).
        I am not putting the assertion into ha_external_lock(F_UNLCK) because
        performance schema tables get closed in the middle of a statement
        sometimes while transaction is disabled.
      sql/sql_table.cc:
        copy_data_between_tables() forgot to clean-up several things in error
        conditions (ha_enable_transaction(), free-ing 'copy', etc) as found
        by the assertion added to sql_parse.cc.
      storage/maria/ha_maria.cc:
        Comment
      storage/maria/ma_blockrec.c:
        fix for Valgrind warning: a temporary table was created, a blob
        page of its was flushed to disk and had random bytes in the checksum
        area ("write of uninitialized bytes in pwrite")
      storage/maria/ma_pagecrc.c:
        typo
      d66157e3
  2. 20 Jan, 2008 1 commit
    • unknown's avatar
      - fix for segfault in rpl_trigger/rpl_found_rows with default engine=maria · 0825c485
      unknown authored
      (fix is keeping the real TRN through a disable_logging/reenable cycle)
      - fix for pagecache assertion failure in ps/type_ranges with default
      engine=maria (fix is in sql_insert.cc)
      - when reenabling logging we must either flush all dirty pages,
      or at least verify (in debug build) that there are none. For example
      a bulk insert with single UNDO_BULK_INSERT must flush them, no matter
      if it uses repair or not (bugfix)
      - UNDO_BULK_INSERT_WITH_REPAIR is also used with repair, changes name
      
      
      mysql-test/r/maria.result:
        tests for bugs fixed
      mysql-test/t/maria.test:
        tests for bugs fixed
      sql/sql_insert.cc:
        Bugfix: even if select_create::prepare() failed to create the 'table' object
        we still have to re-enable logging.
      storage/maria/ha_maria.cc:
        Bugfix: when a transactional table does a bulk insert without
        repair, it still sometimes skips logging of REDOs thus needs a full
        flush and sync at the end. Not if repair is done, as repair does
        it internally already (see end of maria_repair*()).
      storage/maria/ha_maria.h:
        variable now can have 3 states not 2
      storage/maria/ma_bitmap.c:
        name change
      storage/maria/ma_blockrec.c:
        name change
      storage/maria/ma_blockrec.h:
        name change
      storage/maria/ma_check.c:
        * When maria_repair() re-enables logging it does not need to ask for
        a flush&sync as it did it by itself already a few lines before.
        * the log record of bulk insert can be used even without repair
        * disable logging in maria_zerofill(): without that, it puts LSN pages
        in the cache, so when it flushes them it flushes the log; the change
        makes auto-ha_maria::zerofill-if-moved faster (no log flush).
      storage/maria/ma_key_recover.c:
        name change
      storage/maria/ma_loghandler.c:
        name change
      storage/maria/ma_loghandler.h:
        name change
      storage/maria/ma_pagecache.c:
        A function, to check in debug builds that no dirty pages exist for a file.
      storage/maria/ma_pagecache.h:
        new function (nothing in non-debug)
      storage/maria/ma_recovery.c:
        _ma_tmp_disable_logging() sets info->trn to dummy_transaction_object
        when needed now. The changes done here about info->trn are to allow
        a table to retain its original, real TRN through a disable/reenable
        cycle (see replication scenario in _ma_reenable_logging_for_table()).
        When we reenable, we offer the caller to flush and sync the table;
        if the caller doesn't accept our offer, we verify that it's ok
        (no REDOs => no dirty pages are allowed to exist).
      storage/maria/maria_chk.c:
        comment
      storage/maria/maria_def.h:
        new names
      mysql-test/suite/rpl/r/rpl_stm_maria.result:
        result (it used to crash)
      mysql-test/suite/rpl/t/rpl_stm_maria.test:
        Test of replication-specific Maria bug fixed
      0825c485
  3. 19 Jan, 2008 1 commit
    • unknown's avatar
      - fix for bug when creating bitmaps · cd15ea74
      unknown authored
      - fix for bug seen when running test "type_datetime" with Maria
      (wrong data_file_length in maria_repair())
      - fix for bug seen when running test "repair" with Maria
      (myisam_sort_buffer_size was influencing Maria)
      
      
      sql/handler.cc:
        Sounds illogical to store myisam_sort_buffer_size into a structure
        used by all engines. There are only MyISAM and Maria which used 
        sort_buffer_size: they can get their value from their respective
        system variable (myisam|maria_sort_buffer_size). Using MyISAM's value
        for all engines was wrong (myisam_sort_buffer_size influenced Maria).
      sql/handler.h:
        not needed
      storage/maria/ha_maria.cc:
        check_opt->sort_buffer_size was myisam_sort_buffer_size; Maria
        must use maria_sort_buffer_size instead.
      storage/maria/ma_bitmap.c:
        don't use my_chsize() now that Monty re-explained the problem to me :)
      storage/maria/ma_check.c:
        making maria_repair() work like maria_repair_by_sort(): sort_param.filepos
        must be set at start then possibly corrected by create_new_data_handle();
        in the opposite order, filepos is finally set to 0, and if the table
        has no records, it stays 0 and this causes state.data_file_length
        to be 0 which is incorrect for a BLOCK_RECORD table having always
        at least one bitmap page.
      storage/maria/ma_pagecache.c:
        Comments
      storage/myisam/ha_myisam.cc:
        check_opt->sort_buffer_size is gone
      cd15ea74
  4. 18 Jan, 2008 1 commit
    • unknown's avatar
      compiler warnings · 306e09ba
      unknown authored
      
      storage/maria/ma_check.c:
        fix for important compiler warning
      storage/maria/ma_recovery.c:
        fix for compiler warning
      306e09ba
  5. 17 Jan, 2008 2 commits
    • unknown's avatar
      WL#3072 - Maria Recovery · 534417c2
      unknown authored
      Bulk insert: don't log REDO/UNDO for rows, log one UNDO which will
      truncate files; this is an optimization and a bugfix (table was left
      half-repaired by crash).
      Repair: mark table crashed-on-repair at start, bump skip_redo_lsn at start,
      this is easier for recovery (tells it to skip old REDOs or even UNDO
      phase) and user (tells it to repair) in case of crash, sync files
      in the end.
      Recovery skips missing or corrupted table and moves to next record
      (in REDO or UNDO phase) to be more robust; warns if happens in UNDO phase.
      Bugfix for UNDO_KEY_DELETE_WITH_ROOT (tested in ma_test_recovery)
      and maria_enable_indexes().
      Create missing bitmaps when needed (there can be more than one to create,
      in rare cases), log a record for this.
      
      
      include/myisamchk.h:
        new flag: bulk insert repair mustn't bump create_rename_lsn
      mysql-test/lib/mtr_report.pl:
        skip normal warning in maria-recovery.test
      mysql-test/r/maria-recovery.result:
        result: crash before bulk insert is committed, causes proper rollback,
        and crash right after OPTIMIZE replaces index file with new index file
        leads to table marked corrupted and recovery not failing.
      mysql-test/t/maria-recovery.test:
        - can't check the table or it would commit the transaction,
        but check is made after recovery.
        - test of crash before bulk-insert-with-repair is committed
        (to see if it is rolled back), and of crash after OPTIMIZE has replaced
        index file but not finished all operations (to see if recovery fails -
        it used to assert when trying to execute an old REDO on the new
        index).
      storage/maria/CMakeLists.txt:
        new file
      storage/maria/Makefile.am:
        new file
      storage/maria/ha_maria.cc:
        - If bulk insert on a transactional table using an index repair:
        table is initially empty, so don't log REDO/UNDO for data rows
        (optimization), just log an UNDO_BULK_INSERT_WITH_REPAIR
        which will, if executed, empty the data and index file. Re-enable
        logging in end_bulk_insert().
        - write log record for repair operation only after it's fully done,
        index sort including (maria_repair*() used to write the log record).
        - Adding back file->trn=NULL which was removed by mistake earlier.
      storage/maria/ha_maria.h:
        new member (see ha_maria.cc)
      storage/maria/ma_bitmap.c:
        Functions to create missing bitmaps:
        - one function which creates missing bitmaps in page cache, except
        the missing one with max offset which it does not put into page cache
        as it will be modified very soon.
        - one function which the one above calls, and creates bitmaps in page
        cache
        - one function to execute REDO_BITMAP_NEW_PAGE which uses the second
        one above.
      storage/maria/ma_blockrec.c:
        - when logging REDO_DELETE_ALL, not only 'records' and 'checksum'
        has to be reset under log's mutex.
        - execution of REDO_INSERT_ROW_BLOBS now checks the dirty pages' list
        - execution of UNDO_BULK_INSERT_WITH_REPAIR
      storage/maria/ma_blockrec.h:
        new functions
      storage/maria/ma_check.c:
        - table-flush-before-repair is moved to a separate function reused
        by maria_sort_index(); syncing is added
        - maria_repair() is allowed to re-enable logging only if it is the one
        which disabled it.
        - "_ma_flush_table_files_after_repair" was a bad name, it's not after
        repair now, and it should not sync as we do more changes to the files
        shortly after (sync is postponed to when writing the log record)
        - REDO_REPAIR record should be written only after all repair
        operations (in particular after sorting index in ha_mara::repair())
        - close to the end of repair by sort, flushing of pages must happen
        also in the non-quick case, to prepare for the sync at end.
        - in parallel repair, some page flushes are not needed as done
        by initialize_variables_for_repair().
      storage/maria/ma_create.c:
        Update skip_redo_lsn, create_rename_lsn optionally.
      storage/maria/ma_delete_all.c:
        Need to sync files at end of maria_delete_all_rows(), if transactional.
      storage/maria/ma_extra.c:
        During repair, we sometimes call _ma_flush_table_files() (via
        _ma_flush_table_files_before_swap()) while there is a WRITE_CACHE.
      storage/maria/ma_key_recover.c:
        - when we see CLR_END for UNDO_BULK_INSERT_WITH_REPAIR, re-enable
        indices.
        - fixing bug: _ma_apply_undo_key_delete() parsed UNDO_KEY_DELETE_WITH_ROOT
        wrongly, leading to recovery failure
      storage/maria/ma_key_recover.h:
        new prototype
      storage/maria/ma_locking.c:
        DBUG_VOID_RETURN missing
      storage/maria/ma_loghandler.c:
        UNDO for bulk insert with repair, and REDO for creating bitmaps.
        LOGREC_FIRST_FREE to not have to change the for() every time we
        add a new record type.
      storage/maria/ma_loghandler.h:
        new UNDO and REDO
      storage/maria/ma_open.c:
        Move share.kfile.file=kfile up a bit, so that _ma_update_state_lsns()
        can get its value, this fixes a bug where LSN_REPAIRED_BY_MARIA_CHK
        was not corrected on disk by maria_open().
        Store skip_redo_lsn in index' header.
        maria_enable_indexes() had a bug for BLOCK_RECORD, where an empty
        file has one page, not 0 bytes.
      storage/maria/ma_recovery.c:
        - Skip a corrupted, missing, or repaired-with-maria_chk, table in
        recovery: don't fail, just go to next REDO or UNDO; but if an UNDO
        is skipped in UNDO phase we issue warnings.
        - Skip REDO|UNDO in REDO phase if <skip_redo_lsn.
        - If UNDO phase fails, delete transactions to not make trnman
        assert.
        - Update skip_redo_lsn when playing REDO_CREATE_TABLE
        - Don't record UNDOs for old transactions which we don't know (long_trid==0)
        - Bugfix for UNDO_KEY_DELETE_WITH_ROOT (see ma_key_recover.c)
        - Execution of UNDO_BULK_INSERT_WITH_REPAIR
        - Don't try to find a page number in REDO_DELETE_ALL
        - Pieces moved to ma_recovery_util.c
      storage/maria/ma_rename.c:
        name change
      storage/maria/ma_static.c:
        I modified layout of the index' header (inserted skip_redo_lsn in its middle)
      storage/maria/ma_test2.c:
        allow breaking the test towards the end, tests execution of
        UNDO_KEY_DELETE_WITH_ROOT
      storage/maria/ma_test_recovery.expected:
        6 as testflag instead of 4
      storage/maria/ma_test_recovery:
        Increase the amount of rollback work to do when testing recovery
        with ma_test2; this reproduces the UNDO_KEY_DELETE_WITH_ROOT bug.
      storage/maria/maria_chk.c:
        skip_redo_lsn should be updated too, for consistency.
        Write a REDO_REPAIR after all operations (including sort-records)
        have been done.
        No reason to flush blocks after maria_chk_data_link() and
        maria_sort_records(), there is maria_close() in the end.
        write_log_record() is a function, to not clutter maria_chk().
      storage/maria/maria_def.h:
        New member skip_redo_lsn in the state, and comments
      storage/maria/maria_pack.c:
        skip_redo_lsn should be updated too, for consistency
      storage/maria/ma_recovery_util.c:
        _ma_redo_not_needed_for_page(), defined in ma_recovery.c, is needed
        by ma_blockrec.c; this causes link issues, resolved by putting
        _ma_redo_not_needed_for_page() into a new file (so that it is not
        in the same file as repair-related objects of ma_recovery.c).
      storage/maria/ma_recovery_util.h:
        new file
      534417c2
    • unknown's avatar
      ma_checkpoint.c, ma_recovery.c: · 8382126a
      unknown authored
        SCCS merged
      ma_check.c:
        Auto merged
      
      
      storage/maria/ma_check.c:
        Auto merged
      storage/maria/ma_checkpoint.c:
        SCCS merged
      storage/maria/ma_recovery.c:
        SCCS merged
      8382126a
  6. 14 Jan, 2008 1 commit
    • unknown's avatar
      Moved variables to ma_static.c to avoid link error on MacOSX · 5b18f810
      unknown authored
      Added suppress rule for dlclose() in valgrind.supp
      
      
      mysql-test/valgrind.supp:
        Removed duplication
        Added error in dlclose() noticed on pushbuild for x86_64
      storage/maria/ma_init.c:
        Moved variables to ma_static.c to avoid link error on MacOSX
      storage/maria/ma_loghandler.c:
        Moved variables to ma_static.c to avoid link error on MacOSX
      storage/maria/ma_static.c:
        Moved variables to ma_static.c to avoid link error on MacOSX
      5b18f810
  7. 12 Jan, 2008 13 commits
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-maria · 50e27881
      unknown authored
      into  mysql.com:/home/my/mysql-maria
      
      
      mysys/my_getsystime.c:
        Auto merged
      50e27881
    • unknown's avatar
      Fixed compiler warnings · 89ff50d4
      unknown authored
      Fixed type that caused windows builds to fail
      
      
      include/my_alloc.h:
        Use size_t for memory areas instead of uint
      mysys/mf_iocache.c:
        Fixed compiler warnings by adding casts
      mysys/my_compress.c:
        Fixed compiler warnings by adding casts
      mysys/my_getsystime.c:
        Fixed typo
      mysys/my_static.h:
        Use size_t for memory areas
      mysys/safemalloc.c:
        Use size_t for memory areas
      storage/maria/ma_bitmap.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_blockrec.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_cache.c:
        Use size_t for memory areas
      storage/maria/ma_info.c:
        Use size_t for memory areas
      storage/maria/ma_key.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_locking.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_open.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_packrec.c:
        Fixed compiler warnings by fixing type for variable
      storage/maria/ma_statrec.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_write.c:
        Fixed compiler warnings by adding casts
      storage/maria/maria_def.h:
        Use size_t for memory areas
      storage/myisam/mi_search.c:
        Fixed compiler warnings by adding casts
      89ff50d4
    • unknown's avatar
      plug.in: · bb7d835b
      unknown authored
        two MYSQL_PLUGIN_ACTIONS() merged
      my_getsystime.c:
        typos fixed
      
      
      mysys/my_getsystime.c:
        typos fixed
      storage/maria/plug.in:
        two MYSQL_PLUGIN_ACTIONS() merged
      bb7d835b
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-maria · 3f763b67
      unknown authored
      into  janus.mylan:/usr/home/serg/Abk/mysql-maria
      
      
      3f763b67
    • unknown's avatar
      The unused (yet) variable removed. · 496f50fa
      unknown authored
      496f50fa
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-maria · 106b955d
      unknown authored
      into  janus.mylan:/usr/home/serg/Abk/mysql-maria
      
      
      106b955d
    • unknown's avatar
      maria_dump_log - log interpreter added. · 83b6f696
      unknown authored
      
      storage/maria/Makefile.am:
        maria_dump_log build.
      storage/maria/ma_loghandler.c:
        Fixed page size in the log header to be independent of #defines.
        maria_dump_log - log interpreter added.
      83b6f696
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-maria · 7a231b26
      unknown authored
      into  janus.mylan:/usr/home/serg/Abk/mysql-maria
      
      
      7a231b26
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-maria · f0ce8241
      unknown authored
      into  janus.mylan:/usr/home/serg/Abk/mysql-maria
      
      
      f0ce8241
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-maria · 0cccfe30
      unknown authored
      into  mysql.com:/home/my/mysql-maria
      
      
      storage/maria/ma_loghandler.c:
        Auto merged
      0cccfe30
    • unknown's avatar
      Fixes to bugs and compiler warnings detected by pushbuild · 978f3e3c
      unknown authored
      Don't compare uuid's on maria_open() if table is not transactional
      Fixed that my_microtime() works on windows (patch added from 5.1)
      
      
      mysql-test/r/create.result:
        Portability fix
      mysql-test/t/create.test:
        Portability fix
      mysql-test/t/maria.test:
        Remove warnings, to make test portable to windows
      mysys/my_getsystime.c:
        Add missed merge from 5.1
        This fixes that timing works on windows and fixes that that failed becasuse slow_query_log didn't get any queries
      storage/maria/ma_check.c:
        Removed not needed setting of variable
      storage/maria/ma_loghandler.c:
        Fixed compiler warnings
      storage/maria/ma_open.c:
        Don't compare uuid's if table is not transactional
      KNOWN_BUGS.txt:
        New BitKeeper file ``KNOWN_BUGS.txt''
      978f3e3c
    • unknown's avatar
      Merge desktop.sanja.is.com.ua:/home/bell/mysql/bk/mysql-maria · ade00215
      unknown authored
      into  desktop.sanja.is.com.ua:/home/bell/mysql/bk/work-maria-pin
      
      
      storage/maria/ma_loghandler.c:
        Auto merged
      storage/maria/ma_recovery.c:
        Auto merged
      ade00215
    • unknown's avatar
      Multigroup record write fixed. · c2b840be
      unknown authored
      Memory leak fixed.
      Some other small cahnges.
      
      
      mysql-test/include/wait_until_connected_again.inc:
        increased time for recovery (to be able use with --debug)
      mysql-test/r/maria-recovery.result:
        Result fixed.
      storage/maria/ma_loghandler.c:
        Multigroup record write fixed.
        Function for skipping to the next page while filling buffer with
          unlocked handler added.
        Removed possible memory leaks.
        More debug.
      storage/maria/ma_recovery.c:
        Memory leak fixed.
      c2b840be
  8. 11 Jan, 2008 10 commits
    • unknown's avatar
      WL#3072 Maria Recovery · 17f07388
      unknown authored
      All statements doing an implicit commit now also do one in Maria.
      This is useful because LOCK TABLES; REPAIR; crash; is not rollback-able,
      the implicit commit of REPAIR avoid that Recovery tries to rollback
      and fails.
      Fix for BUG#33827 "COMMIT AND CHAIN causes serious Valgrind error"
      (maybe not the definite one, depends on the assigned dev).
      
      
      mysql-test/t/maria-recovery.test:
        test of REPAIR's implicit commit. I cannot commit the result file
        because maria-recovery fails in vanilla tree (seen in pushbuild) but
        its new section looks like:
        repair table t1;
        Table   Op      Msg_type        Msg_text
        mysqltest.t1    repair  status  OK
        insert into t1 values(2);
        select * from t1;
        a
        1
        2
        3
        SET SESSION debug="+d,maria_flush_whole_log,maria_flush_whole_page_cache,maria_crash";
        * crashing mysqld intentionally
        set global maria_checkpoint_interval=1;
        ERROR HY000: Lost connection to MySQL server during query
        * recovery happens
        check table t1 extended;
        Table   Op      Msg_type        Msg_text
        mysqltest.t1    check   status  OK
        * testing that checksum after recovery is as expected
        Checksum-check
        failure
        use mysqltest;
        select * from t1;
        a
        1
        3
        Which is as it should be.
      sql/rpl_injector.cc:
        fix for BUG#33827
      sql/sql_parse.cc:
        - All DDLs and mysql_admin_table() (REPAIR etc) use end_actrive_trans()
        to do an implicit commit so we add there an implicit commit of the
        Maria transaction.
        - Fix for BUG#33827
      storage/maria/ha_maria.cc:
        - A method to do implicit commit in Maria
        - After an implicit commit, if it was under LOCK TABLES, the locked
        tables have a stale file->trn: update it.
      storage/maria/ha_maria.h:
        new static method
      storage/maria/ma_check.c:
        bugfix: this disabling of transactionality had the effect that if
        LOCK TABLES; REPAIR; INSERT then the INSERT ran non-transactional
        (so couldn't be undone in case of crash, if, by bad chance, its
        effect on pages went to disk).
      storage/maria/ma_checkpoint.c:
        indentation
      storage/maria/ma_recovery.c:
        dbug statements
      storage/maria/trnman.c:
        When doing an implicit commit we need to know the number of locked
        tables of the committed transaction and copy it to the new transaction
      storage/maria/trnman_public.h:
        prototype change
      17f07388
    • unknown's avatar
      use AC_HELP_STRING() and MYSQL_PLUGIN_ACTIONS() · 2f83a4ed
      unknown authored
      2f83a4ed
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-maria · 84b71ac9
      unknown authored
      into  janus.mylan:/usr/home/serg/Abk/mysql-maria
      
      
      84b71ac9
    • unknown's avatar
      handshake.cpp: · f1627aab
      unknown authored
        SCCS merged
      
      
      extra/yassl/src/handshake.cpp:
        SCCS merged
      f1627aab
    • unknown's avatar
      Fixed compiler warnings by adding casts and changing variable types · e689fbc4
      unknown authored
      Fixed bug that caused change_user.test to fail
      Fixed bug that caused mysql_client_test to fail
      
      
      include/myisam.h:
        Fixed prototypes
      mysql-test/r/create.result:
        Fix that test works even if Maria is not used for temporary tables
      mysql-test/t/create.test:
        Fix that test works even if Maria is not used for temporary tables
      sql/mysqld.cc:
        Fixed that default value of max_join_size is set correctly; It needs to match usage in set_var.cc
      sql/set_var.cc:
        Fixed test, now when max_join_size is initialized correctly
      sql/sql_select.cc:
        Fixed that one can compile without -DUSE_MARIA_FOR_TMP_TABLES
      storage/maria/ma_blockrec.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_checkpoint.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_create.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_delete_table.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_loghandler.c:
        Fixed compiler warnings by adding casts and changing types for variables
        Changed translog_new_page_header to use changing integer instead of calling time() as time() is a slow call and will give same results when calling many times withing one second
      storage/maria/ma_pagecrc.c:
        Fixed compiler warnings by adding casts
      storage/maria/ma_recovery.c:
        Fixed indentation
      storage/myisam/ha_myisam.cc:
        Fixed wrong types for variables
        Changed chk_data_link() and repair*() functions to take my_bool as argument
      storage/myisam/mi_check.c:
        Fixes to handle that param.test_flag is now ulonglong
      storage/myisam/myisamchk.c:
        Fixes to handle that param.test_flag is now ulonglong
      support-files/compiler_warnings.supp:
        Fixed line numbers
      e689fbc4
    • unknown's avatar
      Merge vvaintroub@bk-internal.mysql.com:/home/bk/mysql-maria · 7bfb3446
      unknown authored
      into  vaio.:C:/bk/maria-wlad
      
      
      storage/maria/ma_loghandler.c:
        Auto merged
      7bfb3446
    • unknown's avatar
      Fix windows warnings using correct datatypes if possible · 45500a70
      unknown authored
      and casts if not.
      Add optional WITH_MARIA_TMP_TABLES parameter to configure.js. This 
      parameter defaults to true, if  WITH_MARIA_STORAGE_ENGINE is present.
      
      
      CMakeLists.txt:
        Add WITH_MARIA_TMP_TABLES config parameter.
      storage/maria/ma_blockrec.c:
        Fix windows warning - use the correct datatype.
      storage/maria/ma_loghandler.c:
        Fix windows warnings by adding casts.
      storage/maria/ma_pagecache.c:
        Fix windows warning - use the correct datatype.
      storage/maria/ma_recovery.c:
        Fix windows warning by adding casts.
      win/configure.js:
        Add WITH_MARIA_TMP_TABLES. If WITH_MARIA_STORAGE_ENGINE is present,
        it defaults to TRUE. To unset, pass  WITH_MARIA_TMP_TABLES=FALSE to 
        configure.js
      45500a70
    • unknown's avatar
      Merge janus.mylan:/data0/mysqldev/users/serg/mysql-5.0-release · 47e76c62
      unknown authored
      into  janus.mylan:/data0/mysqldev/users/serg/mysql-5.1-release
      
      
      extra/yassl/src/template_instnt.cpp:
        Auto merged
      extra/yassl/src/yassl_imp.cpp:
        Auto merged
      47e76c62
    • unknown's avatar
      Bug#33814 - yassl problems · d8ca1f6c
      unknown authored
      
      extra/yassl/src/template_instnt.cpp:
        new template instantiation
      d8ca1f6c
    • unknown's avatar
      The assert fixed. · 2a9d6a0c
      unknown authored
      2a9d6a0c
  9. 10 Jan, 2008 8 commits
    • unknown's avatar
      Added --loose-skip-maria to MYSQLD_BOOTSTRAP_CMD to get bootstrap.test to work · 266fde77
      unknown authored
      Allow one to run bootstrap even if --skip-maria is used (needed for bootstrap.test)
      Fixed lots of compiler warnings
      
      NOTE:
      maria-big and maria-recover tests failes becasue of bugs in transaction log handling.
      Sanja knows about this and is working on it!
      
      
      mysql-test/mysql-test-run.pl:
        Added --loose-skip-maria to MYSQLD_BOOTSTRAP_CMD to get bootstrap.test to work
      mysql-test/r/maria-recovery.result:
        Updated results
      mysql-test/t/bootstrap.test:
        Removed not needed empty line
      mysql-test/t/change_user.test:
        Fixed results for 32 bit systems
      mysql-test/t/maria-big.test:
        Only run this when you use --big
      mysql-test/t/maria-recovery.test:
        Added test case for recovery with big blobs
      mysys/my_uuid.c:
        Fixed compiler warning
      sql/mysqld.cc:
        Allow one to run bootstrap even if --skip-maria is used (needed for bootstrap.test)
      sql/set_var.cc:
        Compare max_join_size with ULONG_MAX instead of HA_POS_ERROR as we set max_join_size to ULONG_MAX by default
      storage/maria/ma_bitmap.c:
        Added __attribute((unused)) to fix compiler warning
      storage/maria/ma_blockrec.c:
        Added casts to remove compiler warnings
        Change variable types to avoid compiler warnings
      storage/maria/ma_check.c:
        Added casts to remove compiler warnings
      storage/maria/ma_checkpoint.c:
        Change variable types to avoid compiler warnings
      storage/maria/ma_create.c:
        Change variable types to avoid compiler warnings
      storage/maria/ma_delete.c:
        Added casts to remove compiler warnings
      storage/maria/ma_key_recover.c:
        Added casts to remove compiler warnings
      storage/maria/ma_loghandler.c:
        Moved initiazation of prev_buffer first as this could otherwise not be set in case of errors
      storage/maria/ma_page.c:
        Added casts to remove compiler warnings
      storage/maria/ma_pagecache.c:
        Added __attribute((unused)) to fix compiler warning
      storage/maria/ma_pagecrc.c:
        Added #ifndef DBUG_OFF to remove compiler warning
      storage/maria/ma_recovery.c:
        Added casts to remove compiler warnings
      storage/maria/ma_write.c:
        Added casts to remove compiler warnings
      storage/maria/maria_chk.c:
        Split long string into two to avoid compiler warnings
      storage/myisam/ft_boolean_search.c:
        Added LINT_INIT() to remove compiler warning
      support-files/compiler_warnings.supp:
        Suppress wrong compiler warning
      unittest/mytap/tap.c:
        Fixed declaration to match prototypes to remove compiler warnings
      266fde77
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-maria · 674f0198
      unknown authored
      into  mysql.com:/home/my/mysql-maria
      
      
      sql/mysqld.cc:
        Auto merged
      storage/maria/ma_check.c:
        Auto merged
      storage/maria/ma_create.c:
        Auto merged
      storage/maria/ma_recovery.c:
        Auto merged
      storage/maria/ma_test2.c:
        Auto merged
      storage/maria/maria_def.h:
        Auto merged
      storage/maria/maria_pack.c:
        Auto merged
      storage/myisam/mi_test2.c:
        Auto merged
      storage/maria/ma_pagecache.c:
        Auto merged
      storage/maria/ha_maria.cc:
        Manual (trival) merge
      674f0198
    • unknown's avatar
      Added --with-maria-tmp-tables (default one) to allow on to configure if Maria... · 5ad477f6
      unknown authored
      Added --with-maria-tmp-tables (default one) to allow on to configure if Maria should be used for internal temporary tables
      Abort mysqld if Maria engine didn't start and we are using Maria for temporary tables
      Fixed bug that caused update of big blobs to crash
      Use pagecache_page_no_t as type for pages (to get rid of compiler warnings)
      Added cast to get rid of compiler warning
      Fixed wrong types of variables and arguments that caused lost information
      Fixed wrong DBUG_ASSERT() that caused REDO of big blobs to fail
      Removed some historical ifdefs that caused problem with windows compilations
      
      
      BUILD/SETUP.sh:
        Added --with-maria-tmp-tables
      include/maria.h:
        Use pagecache_page_no_t as type for pages
        Use my_bool as parameter for 'rep_quick' option
      include/my_base.h:
        Added comment
      mysql-test/r/maria-big.result:
        Added test that uses big blobs
      mysql-test/t/maria-big.test:
        Added test that uses big blobs
      sql/mysqld.cc:
        Abort mysqld if Maria engine didn't start and we are using Maria for temporary tables
      sql/sql_class.h:
        Don't use Maria for temporary tables if --with-maria-tmp-tables is not defined
      sql/sql_select.cc:
        Don't use Maria for temporary tables if --with-maria-tmp-tables is not defined
      storage/maria/ha_maria.cc:
        Fixed compiler warnings reported by MCC
        - Fixed usage of wrong types that caused data loss
        - Changed parameter for rep_quick to my_bool
        - Added safe casts
        
        Fixed indentation
      storage/maria/ma_bitmap.c:
        Use pagecache_page_no_t as type for pages
        Fixed compiler warnings
        Fixed bug that caused update of big blobs to crash
      storage/maria/ma_blockrec.c:
        Use pagecache_page_no_t as type for pages
        Use my_bool as parameter for 'rep_quick' option
        Fixed compiler warnings
        Fixed wrong DBUG_ASSERT()
      storage/maria/ma_blockrec.h:
        Use pagecache_page_no_t as type for pages
      storage/maria/ma_check.c:
        Fixed some wrong parameters where we didn't get all bits for test_flag
        Changed rep_quick to be of type my_bool
        Use pagecache_page_no_t as type for pages
        Added cast's to get rid of compiler warnings
        Changed type of record_pos to get rid of compiler warning
      storage/maria/ma_create.c:
        Added safe cast's to get rid of compiler warnings
      storage/maria/ma_dynrec.c:
        Fixed usage of wrong type
      storage/maria/ma_key.c:
        Fixed compiler warning
      storage/maria/ma_key_recover.c:
        Use pagecache_page_no_t as type for pages
      storage/maria/ma_loghandler_lsn.h:
        Added cast's to get rid of compiler warnings
      storage/maria/ma_page.c:
        Changed variable name from 'page' to 'pos' as it was an offset and not a page address
        Moved page_size inside block to get rid of compiler warning
      storage/maria/ma_pagecache.c:
        Fixed compiler warnings
        Replaced compile time assert with TODO
      storage/maria/ma_pagecache.h:
        Use pagecache_page_no_t as type for pages
      storage/maria/ma_pagecrc.c:
        Allow bitmap pages that is all zero
      storage/maria/ma_preload.c:
        Added cast to get rid of compiler warning
      storage/maria/ma_recovery.c:
        Changed types to get rid of compiler warnings
        Use bool for quick_repair to get rid of compiler warning
        Fixed some variables that was wrongly declared (not enough precission)
        Added cast to get rid of compiler warning
      storage/maria/ma_test2.c:
        Remove historical undefs
      storage/maria/maria_chk.c:
        Changed rep_quick to bool
        Fixed wrong parameter to maria_chk_data_link()
      storage/maria/maria_def.h:
        Use pagecache_page_no_t as type for pages
      storage/maria/maria_pack.c:
        Renamed isam -> maria
      storage/maria/plug.in:
        Added option --with-maria-tmp-tables
      storage/maria/trnman.c:
        Added cast to get rid of compiler warning
      storage/myisam/mi_test2.c:
        Remove historical undefs
      5ad477f6
    • unknown's avatar
      Merge vvaintroub@bk-internal.mysql.com:/home/bk/mysql-maria · 65395ead
      unknown authored
      into  vaio.:C:/bk/maria-wlad
      
      
      65395ead
    • unknown's avatar
      7ecafcd1
    • unknown's avatar
      Merge desktop.sanja.is.com.ua:/home/bell/mysql/bk/mysql-maria · 73c29e82
      unknown authored
      into  desktop.sanja.is.com.ua:/home/bell/mysql/bk/work-maria-pin
      
      
      storage/maria/ma_loghandler.c:
        Auto merged
      73c29e82
    • unknown's avatar
      Fixed syncronization of buffer flush. · 9dd2d08c
      unknown authored
      Debug asserts/prints from Monty.
      No check of mutex operations (by Monty).
      
      
      storage/maria/ma_control_file.c:
        New external function to check mutex ownership.
      storage/maria/ma_loghandler.h:
        No check of mutex operations (by Monty).
        New external function to check mutex ownership.
      9dd2d08c
    • unknown's avatar
      Windows fixes · ce8de7af
      unknown authored
      -new option WITH_MARIA_STORAGE_ENGINE for config.js
      -correct build errors
      -build test executables
      -downport changes for atomic functions from 5.2
      -remove LOCK_uuid_generator from C++ files to avoid linker errors
      -new function my_uuid2str()
      
      
      BitKeeper/deleted/.del-x86-msvc.h:
        Delete: include/atomic/x86-msvc.h
      CMakeLists.txt:
        Windows fixes:
        -New option WITH_MARIA_STORAGE_ENGINE
        -Add unit tests
      include/Makefile.am:
        replace x86-msvc.h with generic-msvc.h
      include/config-win.h:
        my_chmod() support
      include/my_atomic.h:
        Downport my_atomic from 5.2 tree
      include/my_bit.h:
        Correct unresolved symbol errors on Windows
      include/my_pthread.h:
        pthread_mutex_unlock now returns 0 (was void previously)
        defined PTHREAD_STACK_MIN
      include/my_sys.h:
        New function my_uuid2str()
        define MY_UUID_STRING_LENGTH
      include/atomic/nolock.h:
        Downport my_atomic from 5.2 tree
      libmysqld/CMakeLists.txt:
        New option WITH_MARIA_STORAGE_ENGINE
      mysys/CMakeLists.txt:
        Add missing files
      mysys/lf_dynarray.c:
        Fix compiler errors on Windows
      mysys/my_getncpus.c:
        Windows port
      mysys/my_uuid.c:
        Windows fixes: there is no random() on Windows, use ANSI rand()
        New function my_uuid2str()
      mysys/my_winthread.c:
        Downport from 5.2 tree
        -Call my_thread_end() before pthread_exit()
        -Avoid crash if pthread_create is called with NULL attributes
      sql/CMakeLists.txt:
        Link mysqld with Maria storage engine
      sql/item_func.cc:
        Remove LOCK_uuid_generator from C++ to avoid linker errors.
        Use dedicated mutex for short uuids
      sql/item_strfunc.cc:
        Use my_uuid() and my_uuid2str() functions from mysys.
      sql/item_strfunc.h:
        Define MY_UUID_STRING_LENGTH in my_sys.h
      sql/mysql_priv.h:
        LOCK_uuid_generator must be declared as extern "C"
      sql/mysqld.cc:
        Init and destroy LOCK_uuid_short mutex
      storage/maria/CMakeLists.txt:
        -Use the same source files as in Makefile.am
        -Build test binaries
      storage/maria/ha_maria.cc:
        snprintf->my_snprintf
      storage/maria/lockman.c:
        Fix compiler error on Windows
      storage/maria/ma_check.c:
        Fix compiler error on Windows
      storage/maria/ma_loghandler.c:
        Fix compile errors
        my_open()/my_sync() do not work for directories on Windows
      storage/maria/ma_recovery.c:
        Fix compile error on Windows
      storage/maria/ma_test2.c:
        Rename variable to avoid naming conflict with Microsoft C runtime 
        function
      storage/maria/ma_test3.c:
        Fix build errors on Windows
      storage/maria/tablockman.c:
        Fix build errors on Windows
      storage/maria/unittest/Makefile.am:
        Add CMakeLists.txt
      storage/maria/unittest/ma_pagecache_consist.c:
        Fix build errors on Windows
        remove loop from get_len()
      storage/maria/unittest/ma_pagecache_single.c:
        Fix build errors on Windows
      storage/maria/unittest/ma_test_loghandler-t.c:
        Windows fixes
        -Avoid division by 0 in expressions like
        x/(RAND_MAX/y), where y is larger than RAND_MAX(==0x7fff on Windows)
      storage/maria/unittest/ma_test_loghandler_multigroup-t.c:
        Windows fixes
        -Avoid division by 0 in expressions like
        x/(RAND_MAX/y), where y is larger than RAND_MAX(==0x7fff on Windows)
        -remove loop in get_len()
      storage/maria/unittest/ma_test_loghandler_multithread-t.c:
        Windows fixes
        -Avoid division by 0 in expressions like
        x/(RAND_MAX/y), where y is larger than RAND_MAX(==0x7fff on Windows)
        -remove loop in get_len()
      storage/maria/unittest/ma_test_loghandler_noflush-t.c:
        Fix build errors on Windows
      storage/maria/unittest/test_file.c:
        Correct the code to get file size on Windows. 
        stat() information can be outdated and thus cannot be trusted.
        On Vista,stat() returns file size=0 until the file is closed at the
        first time.
      storage/myisam/CMakeLists.txt:
        Fix compiler errors on Windows
        Build test executables
      storage/myisam/mi_test2.c:
        Rename variable to avoid naming conflict with Microsoft C runtime 
        function
      storage/myisam/mi_test3.c:
        Fix build errors on Windows
      strings/CMakeLists.txt:
        Add missing file
      unittest/unit.pl:
        Windows:
        downport unittest changes from 5.2 bk tree
      unittest/mysys/Makefile.am:
        Windows:
        downport unittest changes from 5.2 bk tree
      unittest/mysys/my_atomic-t.c:
        Windows:
        downport unittest changes from 5.2 bk tree
      unittest/mytap/Makefile.am:
        Windows:
        downport unittest changes from 5.2 bk tree
      unittest/mytap/tap.c:
        Windows:
        downport unittest changes from 5.2 bk tree
      win/configure.js:
        Add WITH_MARIA_STORAGE_ENGINE configure option
      unittest/mytap/CMakeLists.txt:
        Add missing file
      unittest/mysys/CMakeLists.txt:
        Add missing file
      storage/maria/unittest/CMakeLists.txt:
        Add missing file
      BitKeeper/etc/ignore:
        Added comments maria-win.patch to the ignore list
      include/atomic/generic-msvc.h:
        Implement atomic operations with MSVC intrinsics
      ce8de7af
  10. 09 Jan, 2008 1 commit