summaryrefslogtreecommitdiff
path: root/unittest
Commit message (Collapse)AuthorAgeFilesLines
* Updated/added copyright header. Added line "use is subject to license terms" Murthy Narkedimilli2014-02-171-0/+1
| | | | to copyright header.
* Bug #16994338 PARSING TAP OUTPUT OF UNIT TEST EXPLAIN_FILENAME-T FAILSAnnamalai Gurusami2013-06-261-1/+1
| | | | | | | | | | | | Problem: The problem is that explain_filename-t is not printing a test plan as required by the TAP protocol. The test invokes plan(NO_PLAN) but does not invoke exit_status() at the end, where the plan would be printed. Solution: Invoke exit_status() at the end.
* Bug#16729109: FIX COMPILATION WARNINGS WITH GCC 4.8Tor Didriksen2013-06-141-1/+1
| | | | | Backport to 5.5 (external Bug#69407 Build warnings with mysql)
* BUG #13619394 - MAKE TEST FAILS ON MY_VSNPRINTF sayantan dutta2013-06-031-5/+0
|
* Merge from 5.5 to 5.6Chaithra Gopalareddy2013-05-232-0/+104
|\
| * Bug#11766191:INVALID MEMORY READ IN DO_DIV_MOD WITH DOUBLY ASSIGNED VARIABLESChaithra Gopalareddy2013-05-223-3/+107
| | | | | | | | | | | | Bug#12608543: CRASHES WITH DECIMALS AND STATEMENT NEEDS TO BE REPREPARED ERRORS Backporting these two fixes to 5.1 Added unittest to test my_decimal construtor and assignment operators
| * Bug 16395495 - OLD FSF ADDRESS IN GPL HEADERMurthy Narkedimilli2013-03-192-2/+2
| |
| * Updated/added copyright headers.Murthy Narkedimilli2013-02-252-2/+2
| |
* | BUG #16813006 - UNIT TEST FOR MY_VSNPRINTF FAIL FOR NON GNU COMPILERsayantan dutta2013-05-161-0/+3
| |
* | Bug #16051728 SERVER CRASHES IN ADD_IDENTIFIER ON CONCURRENT ALTER TABLE ANDAnnamalai Gurusami2013-03-212-1/+173
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SHOW ENGINE INNOD Problem: The purpose of explain_filename() is to provide useful additional information regarding the partitions given the filename. This function was returning an error when it was not able to parse the given filename. For example, within InnoDB, temporary files are created with #sql- prefix. But this function was not able to parse it correctly. Solution: It is not an error, if explain_filename() could not parse the given filename. If there is no partition information to explain, then silently return from the function. rb#1940 approved by mattiasj
* | Fix for Bug 16395495 - OLD FSF ADDRESS IN GPL HEADERMurthy Narkedimilli2013-03-192-2/+2
| |
* | Bug #13619394 - MAKE TEST FAILS ON MY_VSNPRINTF sayantan.dutta@oracle.com2013-02-221-1/+3
| |
* | BUG #13619394: fixing incorrect revertBjorn Munch2012-03-161-1/+1
| | | | | | | | Doing this for Sayantan whose VPN is not working ATM
* | BUG #13619394 - 62572: "MAKE TEST" FAILS ON "MY_VSNPRINTF"Reverting Back ↵sayantan.dutta@oracle.com2012-03-151-1/+1
| | | | | | | | sighting Bar's mail.
* | BUG #13619394: "MAKE TEST" FAILS ON "MY_VSNPRINTF"sayantan.dutta@oracle.com2012-03-141-1/+1
| |
* | Updated/added copyright headersMySQL Build Team2012-02-163-3/+3
|\ \ | |/
| * Updated/added copyright headersKent Boortz2012-02-151-1/+1
| |
| * Fixes required to build on AIXKaren Langford2012-01-111-1/+1
| |
| * Updated/added copyright headersKent Boortz2011-07-031-16/+161
| |\
* | | Bug#13030056 62533: UNITTEST/MYSYS/MY_ATOMIC-T.C DOES NOTJon Olav Hauglid2011-10-031-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | COMPILE ON MACOSX LION The problem was that on optimized builds, the wrong code was generated for my_atomic_add64 if a variable argument was optimized away as a constant. This patch fixes the problem by making the variable volatile. Another workaround is to specify architecture explicitly using e.g. CFLAGS/CXXFLAGS= "-m64". No test case added.
* | | Bug#12727287: Maintainer mode compilation fails with gcc 4.6Davi Arnaut2011-07-071-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GCC 4.6 has new -Wunused-but-set-variable flag, which is enabled by -Wall, that causes GCC to emit a warning whenever a local variable is assigned to, but otherwise unused (aside from its declaration). Since the maintainer mode uses -Wall and -Werror, source code which triggers these warnings will be rejected. That is, these warnings become hard errors. The solution is to fix the code which triggers these specific warnings. In most of the cases, this is a welcome cleanup as code which triggers this warning is probably dead anyway.
* | | Updated/added copyright headersKent Boortz2011-07-041-2/+3
|\ \ \
* \ \ \ Updated/added copyright headersKent Boortz2011-06-3013-19/+24
|\ \ \ \ | |/ / / |/| / / | |/ /
| * | Updated/added copyright headersKent Boortz2011-06-3010-15/+26
| | |
* | | Bug#12552516 LF_HASH REQUIRES MY_THREAD_INIT()Marc Alff2011-05-131-10/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before this fix, a thread instrumented for the performance schema, that would perform file io operations, could crash inside the LF_HASH implementation, in cases when my_thread_init is not called. The crash itself has not been reported in 5.5 but similar crashes have been found in 5.6-based development branches, using LF_HASH for more instrumentation. The possibility of a crash in 5.5 is confirmed by code analysis. The problem is that, when my_thread_init() is not called, which can happen for threads in storage engines or thirs party code, my_thread_var is NULL. Using my_thread_var->stacks_ends_here in mysys/lf_alloc-pin.c is unsafe. Given that my_thread_var is used: - only for stacks_ends_here - only on platform with HAVE_ALLOCA - only when there is enough room on the stack and given that the LF_HASH implementation has a fallback algorythm implemented already when using alloca is not possible, using my_thread_var->stacks_ends_here is in fact not a strict requirement, and can be relaxed. The fix is to: - test explicitly if my_thread_var is NULL, to account for cases when my_thread_init() is not used by the calling thread. - not use alloca in this case, and rely on the fall back code already in place. so that the LF_HASH can be supported even without my_thread_init(). The implementation of mysys/lf_alloc-pin.c has been fixed to support this new usage. The units tests in unittest/mysys/lf-t.c have been adjusted accordingly.
* | | Fix non-portable test of %p in unit test my_vsnprintfBjorn Munch2011-03-021-1/+4
| | |
* | | Bug #11752069 (former bug 43152)Jon Olav Hauglid2011-02-231-1/+1
| | | | | | | | | | | | | | | | | | | | | Assertion `bitmap_is_set_all(&table->s->all_set)' failed in handler::ha_reset Post-push fix for unit test compilation error on Windows.
* | | Merge from mysql-5.1 to mysql-5.5Jon Olav Hauglid2011-02-161-1/+1
|\ \ \ | | |/ | |/| | | | No conflicts
| * | Followup to Bug #11752069 (former bug 43152)Jon Olav Hauglid2011-02-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Assertion `bitmap_is_set_all(&table->s->all_set)' failed in handler::ha_reset This followup fixes the compilation warning 'test_bit' may be used uninitialized in this function introduced by the previous patch.
* | | Merge from mysql-5.1 to mysql-5.5Jon Olav Hauglid2011-02-161-14/+159
|\ \ \ | |/ / | | | | | | | | | | | | Text conflict in include/my_bit.h Text conflict in include/my_bitmap.h Text conflict in mysys/my_bitmap.c
| * | Bug #11752069 (former bug 43152)Jon Olav Hauglid2011-02-161-14/+159
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Assertion `bitmap_is_set_all(&table->s->all_set)' failed in handler::ha_reset This assertion could be triggered if two connections simultaneously executed two bitmap test functions on the same bitmap. For example, the assertion could be triggered if one connection executed UPDATE while a second connection executed SELECT on the same table. Even if bitmap test functions have read-only semantics and have const bitmaps as parameter, several of them modified the internal state of the bitmap. With interleaved execution of two such functions it was possible for one function to modify the state of the same bitmap that the other function had just modified. This lead to an inconsistent state and could trigger the assert. Internally the bitmap uses 32 bit words for storage. Since bitmaps can contain any number of bits, the last word in the bitmap may not be fully used. A 32 bit mask is maintained where a bit is set if the corresponding bit in the last bitmap word is unused. The problem was that several test functions applied this mask to the last word. Sometimes the mask was negated and used to zero out the remainder of the last word and sometimes the mask was used as-is to fill the remainder of the last word with 1's. This meant that if a function first used the negated mask and another function then used the mask as-is (or vice-versa), the first function would then get the wrong result. This patch fixes the problem by changing the implementation of 9 bitmap functions that modified the bitmap state even if the bitmap was declared const. These functions now preserve the internal state of the bitmap. This makes it possible for two connections to concurrently execute two of these functions on the same bitmap without issues. The patch also removes dead testing code from my_bitmap.c. These tests have already been moved to unittest/mysys/bitmap-t.c. Existing test coverage of my_bitmap has been extended. No MTR test case added as this would require adding several sync points to the bitmap functions. The patch has been tested with a non-deterministic test case posted on the bug report.
* | WL#5665: Removal of the autotools-based build systemDavi Arnaut2010-11-206-160/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The autotools-based build system has been superseded and is being removed in order to ease the maintenance burden on developers tweaking and maintaining the build system. In order to support tools that need to extract the server version, a new file that (only) contains the server version, called VERSION, is introduced. The file contents are human and machine-readable. The format is: MYSQL_VERSION_MAJOR=5 MYSQL_VERSION_MINOR=5 MYSQL_VERSION_PATCH=8 MYSQL_VERSION_EXTRA=-rc The CMake based version extraction in cmake/mysql_version.cmake is changed to extract the version from this file. The configure to CMake wrapper is retained for backwards compatibility and to support the BUILD/ scripts. Also, a new a makefile target show-dist-name that prints the server version is introduced.
* | merge from 5.5-mtrBjorn Munch2010-11-191-4/+28
|\ \
| * \ Pull in fix from bug#47526 to solve bug#50047.Jonathan Perkin2010-10-141-4/+28
| |\ \
| | * | Bug#47526 unit.pl fails to execute binaries when using Test::Harness 3.10Magnus Blåudd2010-01-041-3/+34
| | | | | | | | | | | | | | | | | | | | - Rewrite unit.pl so it prefers to use TAP::Harness directly. - Also add support for --verbose --noverbose
* | | | Merge of mysql-5.1-bugteam into mysql-5.5-bugteam.Davi Arnaut2010-10-206-15/+43
|\ \ \ \ | |/ / / |/| | / | | |/ | |/|
| * | Bug#45288: pb2 returns a lot of compilation warningsDavi Arnaut2010-10-206-15/+43
| | | | | | | | | Fix assorted compiler warnings.
* | | mergeGeorgi Kodinov2010-10-041-1/+10
|\ \ \
| * | | Fix for Bug#54478 "mysqld crashes during boot when running mtr with --debug ↵Olav Sandstaa2010-09-151-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | option" The crash during boot was caused by a DBUG_PRINT statement in fill_schema_schemata() (in sql_show.cc). This DBUG_PRINT statement contained several instances of %s in the format string and for one of these we gave a NULL pointer as the argument. This caused the call to vsnprintf() to crash when running on Solaris. The fix for this problem is to replace the call to vsnprintf() with my_vsnprintf() which handles that a NULL pointer is passed as argumens for %s. This patch also extends my_vsnprintf() to support %i in the format string.
* | | | merged mysql-5.5 into WL1054-5.5Georgi Kodinov2010-08-163-8/+6
|\ \ \ \ | |/ / /
| * | | Patch for Bug#55854 (MySQL AB should not be AUTHOR, copyright incorrect).Alexander Nozdrin2010-08-123-8/+6
| | | | | | | | | | | | Fixing copyright text.
* | | | Fixed a build error on solaris sparc in the mysql-5.5-wl1054 treeGeorgi Kodinov2010-08-101-1/+1
|/ / /
* | | Auto-merge from mysql-trunk-merge.Alexander Nozdrin2010-07-293-2/+143
|\ \ \
| * \ \ Merge mysql-5.1-bugteam -> mysql-trunk-mergeVasil Dimov2010-07-291-3/+3
| |\ \ \ | | |/ /
| | * | Postfix for BUG#45012.Alexander Barkov2010-07-291-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: The original patch didn't compile on debug_werror due to wrong format in printf("%d") for size_t variables. Fix: Adding cast to (int).
| * | | Merging from mysql-5.1-bugteamAlexander Barkov2010-07-263-2/+143
| |\ \ \ | | |/ /
| | * | Bug#45012 my_like_range_cp932 generates invalid stringAlexander Barkov2010-07-263-2/+143
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: The functions my_like_range_xxx() returned badly formed maximum strings for Asian character sets, which made problems for storage engines. Fix: - Removed a number my_like_range_xxx() implementations, which were in fact dumplicate code pieces. - Using generic my_like_range_mb() instead. - Setting max_sort_char member properly for Asian character sets - Adding unittest/strings/strings-t.c, to test that my_like_range_xxx() return well-formed min and max strings. Notes: - No additional tests in mysql/t/ available. Old tests cover the affected code well enough.
| | * | Bug#22320: my_atomic-t unit test failsDavi Arnaut2010-07-052-212/+0
| | | | | | | | | | | | | | | | | | | | The atomic operations implementation on 5.1 has a few problems, which might cause tests to abort randomly. Since no code in 5.1 uses atomic operations, simply remove the code.
* | | | WL#5498: Remove dead and unused source codeDavi Arnaut2010-07-231-3/+3
| | | | | | | | | | | | Remove Windows related files which aren't used anymore.
* | | | Bug#22320: my_atomic-t unit test failsDavi Arnaut2010-07-231-13/+6
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug#52261: 64 bit atomic operations do not work on Solaris i386 gcc in debug compilation One of the various problems was that the source operand to CMPXCHG8b was marked as a input/output operand, causing GCC to use the EBX register as the destination register for the CMPXCHG8b instruction. This could lead to crashes as the EBX register is also implicitly used by the instruction, causing the value to be potentially garbaged and a protection fault once the value is used to access a position in memory. Another problem was the lack of proper clobbers for the atomic operations and, also, a discrepancy between the implementations for the Compare and Set operation. The specific problems are described and fixed by Kristian Nielsen patches: Patch: 1 Fix bugs in my_atomic_cas*(val,cmp,new) that *cmp is accessed after CAS succeds. In the gcc builtin implementation, problem was that *cmp was read again after atomic CAS to check if old *val == *cmp; this fails if CAS is successful and another thread modifies *cmp in-between. In the x86-gcc implementation, problem was that *cmp was set also in the case of successful CAS; this means there is a window where it can clobber a value written by another thread after successful CAS. Patch 2: Add a GCC asm "memory" clobber to primitives that imply a memory barrier. This signifies to GCC that any potentially aliased memory must be flushed before the operation, and re-read after the operation, so that read or modification in other threads of such memory values will work as intended. In effect, it makes these primitives work as memory barriers for the compiler as well as the CPU. This is better and more correct than adding "volatile" to variables.