Re: [Maria-developers] [Commits] Rev 4274: small cleanup of the SHOW CREATE TABLE code in lp:~maria-captains/maria/10.0
Hi Sergei, looks good. One question inline. On Sat, Jul 05, 2014 at 11:42:16PM +0200, Sergei Golubchik wrote:
At lp:~maria-captains/maria/10.0
------------------------------------------------------------ revno: 4274 revision-id: sergii@pisem.net-20140705214216-npqtc7tz854xqjxo parent: sergii@pisem.net-20140704190257-1z1inye8jd7k7umc committer: Sergei Golubchik <sergii@pisem.net> branch nick: 10.0 timestamp: Sat 2014-07-05 23:42:16 +0200 message: small cleanup of the SHOW CREATE TABLE code ...skip...
=== modified file 'sql/sql_show.cc' --- a/sql/sql_show.cc 2014-06-05 22:07:27 +0000 +++ b/sql/sql_show.cc 2014-07-05 21:42:16 +0000 @@ -1578,27 +1577,32 @@ int store_create_info(THD *thd, TABLE_LI handler *file= table->file; TABLE_SHARE *share= table->s; HA_CREATE_INFO create_info; -#ifdef WITH_PARTITION_STORAGE_ENGINE bool show_table_options= FALSE; -#endif /* WITH_PARTITION_STORAGE_ENGINE */ Why did you remove ifdef-s here? This variable seem to be unused without partitioning.
...skip... Regards, Sergey
Hi, Sergey! On Jul 08, Sergey Vojtovich wrote:
Hi Sergei,
------------------------------------------------------------ revno: 4274 revision-id: sergii@pisem.net-20140705214216-npqtc7tz854xqjxo parent: sergii@pisem.net-20140704190257-1z1inye8jd7k7umc committer: Sergei Golubchik <sergii@pisem.net> branch nick: 10.0 timestamp: Sat 2014-07-05 23:42:16 +0200 message: small cleanup of the SHOW CREATE TABLE code ...skip...
=== modified file 'sql/sql_show.cc' --- a/sql/sql_show.cc 2014-06-05 22:07:27 +0000 +++ b/sql/sql_show.cc 2014-07-05 21:42:16 +0000 @@ -1578,27 +1577,32 @@ int store_create_info(THD *thd, TABLE_LI handler *file= table->file; TABLE_SHARE *share= table->s; HA_CREATE_INFO create_info; -#ifdef WITH_PARTITION_STORAGE_ENGINE bool show_table_options= FALSE; -#endif /* WITH_PARTITION_STORAGE_ENGINE */ Why did you remove ifdef-s here? This variable seem to be unused without partitioning.
...skip...
Simply to have less #ifdefs in the code. If the variable is completely unused, the compiler can figure it out and remove it. But thanks for asking - I'll recompile without partitioning now and if there will be a warning, I'll add __attribute__((unused)). Regards, Sergei
participants (2)
-
Sergei Golubchik
-
Sergey Vojtovich