List:Commits« Previous MessageNext Message »
From:vasil.dimov Date:February 8 2012 12:55pm
Subject:bzr push into mysql-trunk branch (vasil.dimov:3860 to 3861)
View as plain text  
 3861 Vasil Dimov	2012-02-08
      Fix compilation warning with GCC 4.6:
      
      sql_show.cc: In function 'int store_create_info(THD*, TABLE_LIST*, String*, HA_CREATE_INFO*, bool)':
      sql_show.cc:1429:8: error: variable 'show_table_options' set but not used [-Werror=unused-but-set-variable]

    modified:
      sql/sql_show.cc
 3860 Roy Lyseng	2012-02-08
      Refactoring: Remove member and_tables_cache of Item_cond.
      
      The Item_cond class maintains both not_null_tables_cache
      and and_tables_cache to implement the not_null_tables()
      interface. and_tables_cache is only used for conditions of
      type AND, but it is simple to replace its use with
      not_null_tables_cache.
      
      sql/item.h:
        Deleted Item_name_const::const_item() and
        Item_sp_variable::const_item(), as they are the same as for the
        base class.
      
      sql/item_cmpfunc.cc:
        Maintain not_null_tables_cache instead of and_tables_cache.
      
      sql/item_cmpfunc.h:
        Remove member and_tables_cache, remove function not_null_tables()
        for class Item_cond.

    modified:
      sql/item.h
      sql/item_cmpfunc.cc
      sql/item_cmpfunc.h
=== modified file 'sql/sql_show.cc'
--- a/sql/sql_show.cc	revid:roy.lyseng@stripped
+++ b/sql/sql_show.cc	revid:vasil.dimov@stripped
@@ -1426,7 +1426,9 @@ 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 */
   bool foreign_db_mode=  (thd->variables.sql_mode & (MODE_POSTGRESQL |
                                                      MODE_ORACLE |
                                                      MODE_MSSQL |
@@ -1639,7 +1641,9 @@ int store_create_info(THD *thd, TABLE_LI
   packet->append(STRING_WITH_LEN("\n)"));
   if (!(thd->variables.sql_mode & MODE_NO_TABLE_OPTIONS) && !foreign_db_mode)
   {
+#ifdef WITH_PARTITION_STORAGE_ENGINE
     show_table_options= TRUE;
+#endif /* WITH_PARTITION_STORAGE_ENGINE */
 
     /* TABLESPACE and STORAGE */
     if (share->tablespace ||

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-trunk branch (vasil.dimov:3860 to 3861) vasil.dimov8 Feb