summaryrefslogtreecommitdiffstats
path: root/sql/sql_partition.cc
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-07-01 18:15:00 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-07-01 18:15:00 +0000
commita2a2e32c02643a0cec111511220227703fda1cd5 (patch)
tree69cc2b631234c2a8e026b9cd4d72676c61c594df /sql/sql_partition.cc
parentReleasing progress-linux version 1:10.11.8-1~progress7.99u1. (diff)
downloadmariadb-a2a2e32c02643a0cec111511220227703fda1cd5.tar.xz
mariadb-a2a2e32c02643a0cec111511220227703fda1cd5.zip
Merging upstream version 1:11.4.2.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'sql/sql_partition.cc')
-rw-r--r--sql/sql_partition.cc15
1 files changed, 13 insertions, 2 deletions
diff --git a/sql/sql_partition.cc b/sql/sql_partition.cc
index 590c2a50..5d3c7b35 100644
--- a/sql/sql_partition.cc
+++ b/sql/sql_partition.cc
@@ -4105,8 +4105,19 @@ bool verify_data_with_partition(TABLE *table, TABLE *part_table,
uchar *old_rec;
partition_info *part_info;
DBUG_ENTER("verify_data_with_partition");
- DBUG_ASSERT(table && table->file && part_table && part_table->part_info &&
- part_table->file);
+ DBUG_ASSERT(table);
+ DBUG_ASSERT(table->file);
+ DBUG_ASSERT(part_table);
+ DBUG_ASSERT(part_table->file);
+ DBUG_ASSERT(part_table->part_info);
+
+ if (table->in_use->lex->without_validation)
+ {
+ sql_print_warning("Table %`s.%`s was altered WITHOUT VALIDATION: "
+ "the table might be corrupted",
+ part_table->s->db.str, part_table->s->table_name.str);
+ DBUG_RETURN(false);
+ }
/*
Verify all table rows.