Skip to content

Commit b6ebada

Browse files
committed
Merge branch '10.6' into 10.7
2 parents 7d4b2b9 + fe449af commit b6ebada

File tree

344 files changed

+13373
-5520
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

344 files changed

+13373
-5520
lines changed

CMakeLists.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -257,9 +257,11 @@ ENDIF()
257257

258258
INCLUDE(wsrep)
259259

260-
OPTION(WITH_DBUG_TRACE "Enable DBUG_ENTER()/DBUG_EXIT()" ON)
260+
OPTION(WITH_DBUG_TRACE "Enable DBUG_ENTER()/DBUG_RETURN()/DBUG_PRINT()" ON)
261261
IF(WITH_DBUG_TRACE)
262-
ADD_DEFINITIONS(-DDBUG_TRACE)
262+
FOREACH(LANG C CXX)
263+
SET(CMAKE_${LANG}_FLAGS_DEBUG "${CMAKE_${LANG}_FLAGS_DEBUG} -DDBUG_TRACE")
264+
ENDFOREACH()
263265
ENDIF()
264266

265267
# Always enable debug sync for debug builds.

Docs/README-wsrep

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ wsrep_forced_binlog_format=none
365365
special value NONE, meaning that there is no forced binlog format in effect.
366366
This variable was introduced to support STATEMENT format replication during
367367
rolling schema upgrade processing. However, in most cases ROW replication
368-
is valid for asymmetrict schema replication.
368+
is valid for asymmetric schema replication.
369369

370370
State snapshot transfer options.
371371

@@ -416,7 +416,7 @@ wsrep_sst_donor=
416416

417417
6. ONLINE SCHEMA UPGRADE
418418

419-
Schema upgrades mean any data definition statements (DDL statemnents) run
419+
Schema upgrades mean any data definition statements (DDL statements) run
420420
for the database. They change the database structure and are non-
421421
transactional.
422422

@@ -429,7 +429,7 @@ wsrep_sst_donor=
429429

430430
With earlier releases, DDL processing happened always by Total Order
431431
Isolation (TOI) method. With TOI, the DDL was scheduled to be processed in
432-
same transaction seqeuncing 'slot' in each cluster node.
432+
same transaction sequencing 'slot' in each cluster node.
433433
The processing is secured by locking the affected table from any other use.
434434
With TOI method, the whole cluster has part of the database locked for the
435435
duration of the DDL processing.

Docs/myisam.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ HA_EXTRA_NO_KEYREAD=8 Normal read of records (def)
177177
HA_EXTRA_NO_USER_CHANGE=9 No user is allowed to write
178178
HA_EXTRA_KEY_CACHE=10
179179
HA_EXTRA_NO_KEY_CACHE=11
180-
HA_EXTRA_WAIT_LOCK=12 Wait until file is avalably (def)
180+
HA_EXTRA_WAIT_LOCK=12 Wait until file is available (def)
181181
HA_EXTRA_NO_WAIT_LOCK=13 If file is locked, return quickly
182182
HA_EXTRA_WRITE_CACHE=14 Use write cache in ha_write()
183183
HA_EXTRA_FLUSH_CACHE=15 flush write_record_cache

client/mysql_upgrade.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -935,7 +935,7 @@ static int run_mysqlcheck_upgrade(my_bool mysql_db_only)
935935
return 0;
936936
}
937937
verbose("Phase %d/%d: Checking and upgrading %s", ++phase, phases_total, what);
938-
print_conn_args("mysqlcheck");
938+
print_conn_args("mariadb-check");
939939
retch= run_tool(mysqlcheck_path,
940940
NULL, /* Send output from mysqlcheck directly to screen */
941941
defaults_file,
@@ -1451,15 +1451,15 @@ int main(int argc, char **argv)
14511451
}
14521452

14531453
/* Find mysql */
1454-
find_tool(mysql_path, IF_WIN("mysql.exe", "mysql"), self_name);
1454+
find_tool(mysql_path, IF_WIN("mariadb.exe", "mariadb"), self_name);
14551455

14561456
open_mysql_upgrade_file();
14571457

14581458
if (opt_check_upgrade)
14591459
exit(upgrade_already_done(0) == 0);
14601460

14611461
/* Find mysqlcheck */
1462-
find_tool(mysqlcheck_path, IF_WIN("mysqlcheck.exe", "mysqlcheck"), self_name);
1462+
find_tool(mysqlcheck_path, IF_WIN("mariadb-check.exe", "mariadb-check"), self_name);
14631463

14641464
if (opt_systables_only && !opt_silent)
14651465
printf("The --upgrade-system-tables option was used, user tables won't be touched.\n");

client/mysqlshow.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -506,7 +506,7 @@ list_dbs(MYSQL *mysql,const char *wild)
506506
MYSQL_RES *tresult = mysql_list_tables(mysql,(char*)NULL);
507507
if (mysql_affected_rows(mysql) > 0)
508508
{
509-
sprintf(tables,"%6lu",(ulong) mysql_affected_rows(mysql));
509+
snprintf(tables, sizeof(tables), "%6lu",(ulong) mysql_affected_rows(mysql));
510510
rowcount = 0;
511511
if (opt_verbose > 1)
512512
{
@@ -527,13 +527,13 @@ list_dbs(MYSQL *mysql,const char *wild)
527527
}
528528
}
529529
}
530-
sprintf(rows,"%12lu",rowcount);
530+
snprintf(rows, sizeof(rows), "%12lu", rowcount);
531531
}
532532
}
533533
else
534534
{
535-
sprintf(tables,"%6d",0);
536-
sprintf(rows,"%12d",0);
535+
snprintf(tables, sizeof(tables), "%6d" ,0);
536+
snprintf(rows, sizeof(rows), "%12d", 0);
537537
}
538538
mysql_free_result(tresult);
539539
}
@@ -651,7 +651,7 @@ list_tables(MYSQL *mysql,const char *db,const char *table)
651651
}
652652
else
653653
{
654-
sprintf(fields,"%8u",(uint) mysql_num_fields(rresult));
654+
snprintf(fields, sizeof(fields), "%8u", (uint) mysql_num_fields(rresult));
655655
mysql_free_result(rresult);
656656

657657
if (opt_verbose > 1)
@@ -667,10 +667,10 @@ list_tables(MYSQL *mysql,const char *db,const char *table)
667667
rowcount += (unsigned long) strtoull(rrow[0], (char**) 0, 10);
668668
mysql_free_result(rresult);
669669
}
670-
sprintf(rows,"%10lu",rowcount);
670+
snprintf(rows, sizeof(rows), "%10lu", rowcount);
671671
}
672672
else
673-
sprintf(rows,"%10d",0);
673+
snprintf(rows, sizeof(rows), "%10d", 0);
674674
}
675675
}
676676
}

include/my_dbug.h

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@ extern int (*dbug_sanity)(void);
7777
_db_stack_frame_.line= 0; \
7878
} while(0)
7979

80+
#define DBUG_PRINT(keyword,arglist) \
81+
do if (_db_pargs_(__LINE__,keyword)) _db_doprnt_ arglist; while(0)
82+
8083
#ifdef HAVE_ATTRIBUTE_CLEANUP
8184
#define DBUG_ENTER(a) struct _db_stack_frame_ _db_stack_frame_ __attribute__((cleanup(_db_return_))); \
8285
_db_enter_ (a,__FILE__,__LINE__,&_db_stack_frame_)
@@ -94,15 +97,15 @@ extern int (*dbug_sanity)(void);
9497
#define DBUG_ENTER(a)
9598
#define DBUG_RETURN(a1) return(a1)
9699
#define DBUG_VOID_RETURN return
100+
#define DBUG_PRINT(keyword,arglist) do{} while(0)
97101
#endif
98102

99103
#define DBUG_EXECUTE(keyword,a1) \
100104
do {if (_db_keyword_(0, (keyword), 0)) { a1 }} while(0)
101105
#define DBUG_EXECUTE_IF(keyword,a1) \
102106
do {if (_db_keyword_(0, (keyword), 1)) { a1 }} while(0)
107+
103108
#define DBUG_IF(keyword) _db_keyword_(0, (keyword), 1)
104-
#define DBUG_PRINT(keyword,arglist) \
105-
do if (_db_pargs_(__LINE__,keyword)) _db_doprnt_ arglist; while(0)
106109

107110
#define DBUG_PUSH_EMPTY if (_dbug_on_) { DBUG_PUSH(""); }
108111
#define DBUG_POP_EMPTY if (_dbug_on_) { DBUG_POP(); }
@@ -167,6 +170,7 @@ extern void _db_suicide_(void);
167170
#define DBUG_LEAVE
168171
#define DBUG_RETURN(a1) do { return(a1); } while(0)
169172
#define DBUG_VOID_RETURN do { return; } while(0)
173+
#define DBUG_PRINT(keyword, arglist) do { } while(0)
170174
#define DBUG_EXECUTE(keyword,a1) do { } while(0)
171175
#define DBUG_EXECUTE_IF(keyword,a1) do { } while(0)
172176
#define DBUG_IF(keyword) 0

include/my_pthread.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -436,6 +436,7 @@ void safe_mutex_free_deadlock_data(safe_mutex_t *mp);
436436
#define my_cond_wait(A,B) safe_cond_wait((A), (B), __FILE__, __LINE__)
437437
#else
438438

439+
#define safe_mutex_is_owner(mp) (1)
439440
#define safe_mutex_assert_owner(mp) do {} while (0)
440441
#define safe_mutex_assert_not_owner(mp) do {} while (0)
441442
#define safe_mutex_setflags(mp, F) do {} while (0)

include/my_sys.h

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -958,6 +958,17 @@ extern ulonglong my_getcputime(void);
958958
#define hrtime_sec_part(X) ((ulong)((X).val % HRTIME_RESOLUTION))
959959
#define my_time(X) hrtime_to_time(my_hrtime_coarse())
960960

961+
/**
962+
Make high resolution time from two parts.
963+
*/
964+
965+
static inline my_hrtime_t make_hr_time(my_time_t time, ulong time_sec_part)
966+
{
967+
my_hrtime_t res= {((ulonglong) time)*1000000 + time_sec_part};
968+
return res;
969+
}
970+
971+
961972
#if STACK_DIRECTION < 0
962973
#define available_stack_size(CUR,END) (long) ((char*)(CUR) - (char*)(END))
963974
#else

libmariadb

mysql-test/main/alter_table-big.test

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
--source include/big_test.inc
66
# We are using some debug-only features in this test
77
--source include/have_debug.inc
8+
--source include/have_debug_sync.inc
89
# Also we are using SBR to check that statements are executed
910
# in proper order.
1011
--source include/have_binlog_format_mixed_or_statement.inc

0 commit comments

Comments
 (0)