Re: [Maria-developers] MDEV-17658 review.
Hi, Alexey! It's important for USER_TABLE to be last. And there can be only one last value in the enum, if I add TABLES_MAX, someone will eventually put new table just before TABLES_MAX (tests will catch it, but it might take hours to track down to the actual reason). So, it's safer to have just one last element in the enum, USER_TABLE. On Dec 09, Alexey Botchkov wrote:
Hello, Sergei!
I haven't found anything serious to improve there in your changes. sql_acl.cc gets nicer with this patch. So ok to push.
Only question left - - TABLES_MAX // <== always the last + USER_TABLE // <== always the last
Why not preserve the TABLES_MAX? Seems more self-explaining. +static LEX_CSTRING MYSQL_TABLE_NAME[USER_TABLE+1]= could be +static LEX_CSTRING MYSQL_TABLE_NAME[TABLES_MAX]= and a couple of similar places.
Best regards. HF
Regards, Sergei Chief Architect MariaDB and security@mariadb.org
participants (1)
-
Sergei Golubchik