summaryrefslogtreecommitdiff
path: root/sql/slave.h
diff options
context:
space:
mode:
authorunknown <lars@mysql.com>2004-12-03 15:18:25 +0100
committerunknown <lars@mysql.com>2004-12-03 15:18:25 +0100
commitf2d6046eda1d0e210eb6aa68d6d604d2ef824918 (patch)
treea55fd718784f58219ca151ed1d98e1150b07cfdb /sql/slave.h
parentabf0ab9eee5070fd7bd6f284fec8a1ba0216ecb6 (diff)
downloadmariadb-git-f2d6046eda1d0e210eb6aa68d6d604d2ef824918.tar.gz
Due to a compiler bug, slave.cc:tables_ok() sometimes wrongly returns
1 if the return type is int or int_fast8_t. The test case that showed this problem is rpl000001 and the tested version was MySQL 5.0.2. The compiler with the problem is GCC 3.0.4 runing on "Linux bitch 2.4.18 #2 Thu Apr 11 14:37:17 EDT 2002 sparc64 unknown". By changing the return type to bool the problem disappear. (Another way to make the problem disappear is to simply print the returned value with printf("%d",?). The printed returned value is always 0 in the test cases I have run.) This is only a partial solution to the problem, since someone could later change the return type of the function back to int or some other type that does not work. sql/slave.cc: Changed type sql/slave.h: Changed type
Diffstat (limited to 'sql/slave.h')
-rw-r--r--sql/slave.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/slave.h b/sql/slave.h
index a4d123329c6..08cf0806717 100644
--- a/sql/slave.h
+++ b/sql/slave.h
@@ -496,7 +496,7 @@ int show_master_info(THD* thd, MASTER_INFO* mi);
int show_binlog_info(THD* thd);
/* See if the query uses any tables that should not be replicated */
-int tables_ok(THD* thd, TABLE_LIST* tables);
+bool tables_ok(THD* thd, TABLE_LIST* tables);
/*
Check to see if the database is ok to operate on with respect to the