mirror of
https://github.com/MariaDB/server.git
synced 2026-10-23 18:49:29 +03:00
A new assertion added by MDEV-36290 is correct in trying to identify default_fields that weren't correctly accounted in parse_vcol_defs. It caught a case for INSERT DELAYED on tables using TIMESTAMP and DATETIME types with ON UPDATE default values. That is, the insert delayed logic opens the table in one thread, and then copies the field info to another table in the user thread. This copy loses most flag metadata for these fields though. In this case, the flag ON_UPDATE_NOW_FLAG was dropped, and the parse_col_defs() logic was unable to properly account for that default field, and the assertion fired. This patch fixes this by restoring the ON_UPDATE_NOW_FLAG during the field copy. Also, a comment is added to Field::make_new_field() to explain the state of the returned field. Reviewed-by: Monty <monty@mariadb.com> Signed-off-by: Brandon Nesterenko <brandon.nesterenko@mariadb.com>
188 KiB
188 KiB