summaryrefslogtreecommitdiff
path: root/myisam
diff options
context:
space:
mode:
authorunknown <monty@mishka.local>2004-10-20 01:28:42 +0300
committerunknown <monty@mishka.local>2004-10-20 01:28:42 +0300
commit4736d0fe9963742e2788960d60da7f0f2dd593e9 (patch)
tree1919e7f3a6a68e36dbbcf1dd8b6cd8729a975e36 /myisam
parent46b10a307fcaf3449f2bcf3b989feb0e1c53e7b6 (diff)
downloadmariadb-git-4736d0fe9963742e2788960d60da7f0f2dd593e9.tar.gz
Review of all code pushed since last review
Simple optimzations and cleanups Removed compiler warnings and fixed portability issues Added client functions 'mysql_embedded()' to allow client to check if we are using embedded server Fixes for purify client/mysqlimport.c: Remove not used variable client/mysqltest.c: Remove usage of MAXPATHLEN (all MySQL code uses FN_REFLEN) Simplified code Remove usage of sprintf("%llu") as this is not portable include/mysql.h: Added mysql_embedded() to be able to easily check if we are using the embedded server innobase/srv/srv0start.c: Don't use memcmp() when using purify (to avoid false warnings) libmysql/libmysql.c: Added mysql_embedded() to be able to easily check if we are using the embedded server libmysql/libmysql.def: Added mysql_embedded() to be able to easily check if we are using the embedded server myisam/myisam_ftdump.c: Remove compiler warning myisam/myisamchk.c: Remove compiler warning myisam/rt_test.c: #ifdef not used code mysys/hash.c: Remove compiler warning (from last push) mysys/my_gethwaddr.c: Remove compiler warning ndb/src/ndbapi/ndberror.c: #ifdef not used code regex/regcomp.c: Remove not used code regex/regcomp.ih: Remove not used code (to remove compiler warnings) sql-common/client.c: Remove compiler warnings sql/field.cc: Simple optimization sql/ha_innodb.cc: Rename mysql_embedded -> mysqld_embedded sql/item.cc: Fix comments Move variables first on block Remove else after return Simple optimizations (no logic changes) sql/item_cmpfunc.cc: Added comment sql/mysql_priv.h: Rename mysql_embedded -> mysqld_embedded sql/mysqld.cc: Rename mysql_embedded -> mysqld_embedded sql/sql_acl.cc: Added comments simple optimization Fixed 'very unlikely' bug when doing REVOKE ALL PRIVILEGES sql/sql_select.cc: More comments Simple optimization sql/sql_show.cc: Simple changes to make similar code similar More comments sql/sql_string.cc: Trivial optimization and better code layout strings/Makefile.am: Change xml.c to use bcmp to avoid warnings from purify strings/xml.c: Change xml.c to use bcmp to avoid warnings from purify tests/client_test.c: Remove usage of MAXPATHLEN (all MySQL code uses FN_REFLEN)
Diffstat (limited to 'myisam')
-rw-r--r--myisam/myisam_ftdump.c2
-rw-r--r--myisam/myisamchk.c2
-rw-r--r--myisam/rt_test.c3
3 files changed, 5 insertions, 2 deletions
diff --git a/myisam/myisam_ftdump.c b/myisam/myisam_ftdump.c
index 8219c19848a..54b2cc77965 100644
--- a/myisam/myisam_ftdump.c
+++ b/myisam/myisam_ftdump.c
@@ -68,7 +68,7 @@ int main(int argc,char *argv[])
struct { MI_INFO *info; } aio0, *aio=&aio0; /* for GWS_IN_USE */
MY_INIT(argv[0]);
- if (error=handle_options(&argc, &argv, my_long_options, get_one_option))
+ if ((error= handle_options(&argc, &argv, my_long_options, get_one_option)))
exit(error);
if (count || dump)
verbose=0;
diff --git a/myisam/myisamchk.c b/myisam/myisamchk.c
index 98cbc838d31..6c0c30b7056 100644
--- a/myisam/myisamchk.c
+++ b/myisam/myisamchk.c
@@ -1695,7 +1695,7 @@ err:
static my_bool not_killed= 0;
-volatile my_bool *killed_ptr(MI_CHECK *param)
+volatile my_bool *killed_ptr(MI_CHECK *param __attribute__((unused)))
{
return &not_killed; /* always NULL */
}
diff --git a/myisam/rt_test.c b/myisam/rt_test.c
index 5e883e223b3..4f04aa11fce 100644
--- a/myisam/rt_test.c
+++ b/myisam/rt_test.c
@@ -425,6 +425,7 @@ static void create_record1(char *record,uint rownr)
}
}
+#ifdef NOT_USED
static void create_record0(char *record,uint rownr)
{
@@ -447,6 +448,8 @@ static void create_record0(char *record,uint rownr)
}
}
+#endif
+
static void create_record(char *record,uint rownr)
{
int i;