summaryrefslogtreecommitdiff
path: root/sql/sql_db.cc
diff options
context:
space:
mode:
authorunknown <bell@sanja.is.com.ua>2004-11-13 19:35:51 +0200
committerunknown <bell@sanja.is.com.ua>2004-11-13 19:35:51 +0200
commit8d71bcec217bead7d832d6ea4dca437c5f134577 (patch)
treea534689811d0f65eba423eed77b056f3bb30bd51 /sql/sql_db.cc
parent067863e184e9a23034d410919d4c8075ee30bcee (diff)
downloadmariadb-git-8d71bcec217bead7d832d6ea4dca437c5f134577.tar.gz
now my_printf_error is not better then my_error, but my_error call is shorter
used only one implementation of format parser of (printf) fixed multistatement include/mysqld_error.h: newerror messages mysql-test/t/key.test: unknown error replaced with real error mysys/my_error.c: my_error & my_printf_error use my_vsprintf sql/field_conv.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/ha_innodb.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/handler.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/item.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/item_cmpfunc.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/item_func.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/item_strfunc.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/lock.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/log.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/parse_file.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/procedure.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/protocol.cc: no need reset thd->lex->found_colon to break multiline sequance now, send_error called too late sql/repl_failsafe.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/set_var.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/share/czech/errmsg.txt: new errors converted from unknown error sql/share/danish/errmsg.txt: new errors converted from unknown error sql/share/dutch/errmsg.txt: new errors converted from unknown error sql/share/english/errmsg.txt: new errors converted from unknown error sql/share/estonian/errmsg.txt: new errors converted from unknown error sql/share/french/errmsg.txt: new errors converted from unknown error sql/share/german/errmsg.txt: new errors converted from unknown error sql/share/greek/errmsg.txt: new errors converted from unknown error sql/share/hungarian/errmsg.txt: new errors converted from unknown error sql/share/italian/errmsg.txt: new errors converted from unknown error sql/share/japanese/errmsg.txt: new errors converted from unknown error sql/share/korean/errmsg.txt: new errors converted from unknown error sql/share/norwegian-ny/errmsg.txt: new errors converted from unknown error sql/share/norwegian/errmsg.txt: new errors converted from unknown error sql/share/polish/errmsg.txt: new errors converted from unknown error sql/share/portuguese/errmsg.txt: new errors converted from unknown error sql/share/romanian/errmsg.txt: new errors converted from unknown error sql/share/russian/errmsg.txt: new errors converted from unknown error sql/share/serbian/errmsg.txt: new errors converted from unknown error sql/share/slovak/errmsg.txt: new errors converted from unknown error sql/share/spanish/errmsg.txt: new errors converted from unknown error sql/share/swedish/errmsg.txt: new errors converted from unknown error sql/share/ukrainian/errmsg.txt: new errors converted from unknown error sql/slave.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sp.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sp_head.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_acl.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_analyse.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_base.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_class.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_db.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_delete.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_handler.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_insert.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_load.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_map.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_parse.cc: now my_printf_error is not better then my_error, but my_error call is shorter multi-row command fixed sql/sql_prepare.cc: now my_printf_error is not better then my_error, but my_error call is shorter remover send_error ingected from 4.1 sql/sql_rename.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_repl.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_select.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_show.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_table.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_trigger.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_udf.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_update.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_view.cc: now my_printf_error is not better then my_error, but my_error call is shorter sql/sql_yacc.yy: now my_printf_error is not better then my_error, but my_error call is shorter sql/table.cc: now my_printf_error is not better then my_error, but my_error call is shorter strings/my_vsnprintf.c: * format support added to my_vsprint
Diffstat (limited to 'sql/sql_db.cc')
-rw-r--r--sql/sql_db.cc29
1 files changed, 12 insertions, 17 deletions
diff --git a/sql/sql_db.cc b/sql/sql_db.cc
index 42d6549f843..ad4887146d8 100644
--- a/sql/sql_db.cc
+++ b/sql/sql_db.cc
@@ -408,8 +408,7 @@ bool mysql_create_db(THD *thd, char *db, HA_CREATE_INFO *create_info,
{
if (!(create_options & HA_LEX_CREATE_IF_NOT_EXISTS))
{
- my_printf_error(ER_DB_CREATE_EXISTS, ER(ER_DB_CREATE_EXISTS), MYF(0),
- db);
+ my_error(ER_DB_CREATE_EXISTS, MYF(0), db);
error= -1;
goto exit;
}
@@ -419,13 +418,12 @@ bool mysql_create_db(THD *thd, char *db, HA_CREATE_INFO *create_info,
{
if (my_errno != ENOENT)
{
- my_printf_error(EE_STAT, ER(EE_STAT), MYF(0), path, my_errno);
+ my_error(EE_STAT, MYF(0), path, my_errno);
goto exit;
}
if (my_mkdir(path,0777,MYF(0)) < 0)
{
- my_printf_error(ER_CANT_CREATE_DB, ER(ER_CANT_CREATE_DB),
- MYF(0), db, my_errno);
+ my_error(ER_CANT_CREATE_DB, MYF(0), db, my_errno);
error= -1;
goto exit;
}
@@ -579,7 +577,7 @@ bool mysql_rm_db(THD *thd,char *db,bool if_exists, bool silent)
if (!if_exists)
{
error= -1;
- my_printf_error(ER_DB_DROP_EXISTS, ER(ER_DB_DROP_EXISTS), MYF(0), db);
+ my_error(ER_DB_DROP_EXISTS, MYF(0), db);
goto exit;
}
else
@@ -803,8 +801,7 @@ static long mysql_rm_known_files(THD *thd, MY_DIR *dirp, const char *db,
*/
if (found_other_files)
{
- my_printf_error(ER_DB_DROP_RMDIR, ER(ER_DB_DROP_RMDIR), MYF(0),
- org_path, EEXIST);
+ my_error(ER_DB_DROP_RMDIR, MYF(0), org_path, EEXIST);
DBUG_RETURN(-1);
}
else
@@ -867,8 +864,7 @@ static my_bool rm_dir_w_symlink(const char *org_path, my_bool send_error)
*--pos=0;
if (rmdir(path) < 0 && send_error)
{
- my_printf_error(ER_DB_DROP_RMDIR, ER(ER_DB_DROP_RMDIR), MYF(0),
- path, errno);
+ my_error(ER_DB_DROP_RMDIR, MYF(0), path, errno);
DBUG_RETURN(-1);
}
DBUG_RETURN(0);
@@ -995,7 +991,7 @@ bool mysql_change_db(THD *thd, const char *name)
}
if (check_db_name(dbname))
{
- my_printf_error(ER_WRONG_DB_NAME, ER(ER_WRONG_DB_NAME), MYF(0), dbname);
+ my_error(ER_WRONG_DB_NAME, MYF(0), dbname);
x_free(dbname);
DBUG_RETURN(1);
}
@@ -1008,11 +1004,10 @@ bool mysql_change_db(THD *thd, const char *name)
thd->master_access);
if (!(db_access & DB_ACLS) && (!grant_option || check_grant_db(thd,dbname)))
{
- my_printf_error(ER_DBACCESS_DENIED_ERROR,
- ER(ER_DBACCESS_DENIED_ERROR), MYF(0),
- thd->priv_user,
- thd->priv_host,
- dbname);
+ my_error(ER_DBACCESS_DENIED_ERROR, MYF(0),
+ thd->priv_user,
+ thd->priv_host,
+ dbname);
mysql_log.write(thd,COM_INIT_DB,ER(ER_DBACCESS_DENIED_ERROR),
thd->priv_user,
thd->priv_host,
@@ -1027,7 +1022,7 @@ bool mysql_change_db(THD *thd, const char *name)
path[length-1]=0; // remove ending '\'
if (access(path,F_OK))
{
- my_printf_error(ER_BAD_DB_ERROR, ER(ER_BAD_DB_ERROR), MYF(0), dbname);
+ my_error(ER_BAD_DB_ERROR, MYF(0), dbname);
my_free(dbname,MYF(0));
DBUG_RETURN(1);
}