[Groonga-mysql-commit] mroonga/mroonga at 9ce6a9f [master] Define GTS_TABLE and use it for all build patterns

Back to archive index

Kouhei Sutou null+****@clear*****
Wed May 8 11:17:28 JST 2013


Kouhei Sutou	2013-05-08 11:17:28 +0900 (Wed, 08 May 2013)

  New Revision: 9ce6a9fec6e2671d0b3bff6892194ca8274c8d65
  https://github.com/mroonga/mroonga/commit/9ce6a9fec6e2671d0b3bff6892194ca8274c8d65

  Message:
    Define GTS_TABLE and use it for all build patterns
    
    It reduces #ifdef in *.cpp.

  Modified files:
    mrn_mysql_compat.h
    mrn_table.cpp

  Modified: mrn_mysql_compat.h (+4 -0)
===================================================================
--- mrn_mysql_compat.h    2013-05-07 19:13:19 +0900 (246e69d)
+++ mrn_mysql_compat.h    2013-05-08 11:17:28 +0900 (fdb244b)
@@ -74,4 +74,8 @@
 #  define init_alloc_root(PTR, SZ1, SZ2, FLAG) init_alloc_root(PTR, SZ1, SZ2)
 #endif
 
+#if MYSQL_VERSION_ID < 100002 || !defined(MRN_MARIADB_P)
+#  define GTS_TABLE 0
+#endif
+
 #endif /* _mrn_mysql_compat_h */

  Modified: mrn_table.cpp (+0 -4)
===================================================================
--- mrn_table.cpp    2013-05-07 19:13:19 +0900 (371d8cb)
+++ mrn_table.cpp    2013-05-08 11:17:28 +0900 (74ee20a)
@@ -952,11 +952,7 @@ TABLE_SHARE *mrn_create_tmp_table_share(TABLE_LIST *table_list, const char *path
   share->path.length = strlen(path);
   share->normalized_path.str = share->path.str;
   share->normalized_path.length = share->path.length;
-#if MYSQL_VERSION_ID >= 100002 && defined(MRN_MARIADB_P)
   if (open_table_def(thd, share, GTS_TABLE))
-#else
-  if (open_table_def(thd, share, 0))
-#endif
   {
     *error = ER_CANT_OPEN_FILE;
     DBUG_RETURN(NULL);
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-mysql-commit mailing list
Back to archive index