Commit 5bd51725 authored by Vladislav Vaintroub's avatar Vladislav Vaintroub

MDEV-25815 mariabackup crash or debug assert with --backup --databases-exclude

Fix regression (debug assertion or division by 0)
caused by cfd3d70c
parent a70a5537
......@@ -4048,7 +4048,7 @@ xb_register_filter_entry(
strncpy(dbname, name, p - name);
dbname[p - name] = 0;
if (databases_hash) {
if (databases_hash && databases_hash->array) {
HASH_SEARCH(name_hash, databases_hash,
ut_fold_string(dbname),
xb_filter_entry_t*,
......
......@@ -8,7 +8,7 @@ mkdir $targetdir;
let $streamfile=$MYSQLTEST_VARDIR/tmp/backup.xb;
echo # xtrabackup backup to stream;
exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --stream=xbstream > $streamfile 2>$targetdir/backup_stream.log;
exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --databases-exclude=foobar --stream=xbstream > $streamfile 2>$targetdir/backup_stream.log;
echo # xbstream extract;
--disable_result_log
exec $XBSTREAM -x -C $targetdir < $streamfile;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment