summaryrefslogtreecommitdiff
path: root/sql/sql_udf.cc
diff options
context:
space:
mode:
authorAlexander Nozdrin <alik@sun.com>2010-01-31 00:12:29 +0300
committerAlexander Nozdrin <alik@sun.com>2010-01-31 00:12:29 +0300
commit2cdad6c3eb353cc4d986c274caad2dad5eaa6494 (patch)
treef2eeac784b7db952ba98d0ce33063cd5fdcf1b2f /sql/sql_udf.cc
parent7e4234b4f5c60747fecf17a2ffcd4d11199fca04 (diff)
parent5aa4c33e3233e2c1cac9f3bb0b17379a56503666 (diff)
downloadmariadb-git-2cdad6c3eb353cc4d986c274caad2dad5eaa6494.tar.gz
Manual merge from mysql-trunk-merge.
Conflicts: - mysql-test/suite/binlog/t/binlog_write_error.test - sql/log.cc - sql/log_event.cc - sql/log_event_old.cc - sql/mysql_priv.h - sql/sp.cc - sql/sql_acl.cc - sql/sql_base.cc - sql/sql_delete.cc - sql/sql_insert.cc - sql/sql_load.cc - sql/sql_table.cc - sql/sql_udf.cc - sql/sql_update.cc - sql/sql_view.cc
Diffstat (limited to 'sql/sql_udf.cc')
-rw-r--r--sql/sql_udf.cc10
1 files changed, 8 insertions, 2 deletions
diff --git a/sql/sql_udf.cc b/sql/sql_udf.cc
index 57c9110405a..d0e446fb157 100644
--- a/sql/sql_udf.cc
+++ b/sql/sql_udf.cc
@@ -531,8 +531,11 @@ int mysql_create_function(THD *thd,udf_func *udf)
/* Binlog the create function. */
if (write_bin_log(thd, TRUE, thd->query(), thd->query_length()))
+ {
+ /* Restore the state of binlog format */
+ thd->current_stmt_binlog_row_based= save_binlog_row_based;
DBUG_RETURN(1);
-
+ }
/* Restore the state of binlog format */
thd->current_stmt_binlog_row_based= save_binlog_row_based;
DBUG_RETURN(0);
@@ -612,8 +615,11 @@ int mysql_drop_function(THD *thd,const LEX_STRING *udf_name)
/* Binlog the drop function. */
if (write_bin_log(thd, TRUE, thd->query(), thd->query_length()))
+ {
+ /* Restore the state of binlog format */
+ thd->current_stmt_binlog_row_based= save_binlog_row_based;
DBUG_RETURN(1);
-
+ }
/* Restore the state of binlog format */
thd->current_stmt_binlog_row_based= save_binlog_row_based;
DBUG_RETURN(0);