summaryrefslogtreecommitdiff
path: root/sql/sp_head.h
diff options
context:
space:
mode:
authorAlexander Nozdrin <alik@sun.com>2010-01-21 12:14:34 +0300
committerAlexander Nozdrin <alik@sun.com>2010-01-21 12:14:34 +0300
commitb78e3a5d1efff8958a2ac44efadbefacaba0f163 (patch)
tree1a7e0403e8ed7b5ae817b8249812184027c9cd68 /sql/sp_head.h
parent31740ffdfcc651f9b6ebc335110fa498b3bc13fd (diff)
parent47ac59608056bae83a3196e2feefe7d7631218e7 (diff)
downloadmariadb-git-b78e3a5d1efff8958a2ac44efadbefacaba0f163.tar.gz
Auto-merge from mysql-next-mr.
Diffstat (limited to 'sql/sp_head.h')
-rw-r--r--sql/sp_head.h24
1 files changed, 16 insertions, 8 deletions
diff --git a/sql/sp_head.h b/sql/sp_head.h
index 81cb907a5a1..fd02c799975 100644
--- a/sql/sp_head.h
+++ b/sql/sp_head.h
@@ -165,9 +165,8 @@ public:
HAS_COMMIT_OR_ROLLBACK= 128,
LOG_SLOW_STATEMENTS= 256, // Used by events
LOG_GENERAL_LOG= 512, // Used by events
- BINLOG_ROW_BASED_IF_MIXED= 1024,
- HAS_SQLCOM_RESET= 2048,
- HAS_SQLCOM_FLUSH= 4096
+ HAS_SQLCOM_RESET= 1024,
+ HAS_SQLCOM_FLUSH= 2048
};
/** TYPE_ENUM_FUNCTION, TYPE_ENUM_PROCEDURE or TYPE_ENUM_TRIGGER */
@@ -198,6 +197,11 @@ public:
private:
Stored_program_creation_ctx *m_creation_ctx;
+ /**
+ Boolean combination of (1<<flag), where flag is a member of
+ LEX::enum_binlog_stmt_unsafe.
+ */
+ uint32 unsafe_flags;
public:
inline Stored_program_creation_ctx *get_creation_ctx()
@@ -453,20 +457,24 @@ public:
#endif
/*
- This method is intended for attributes of a routine which need
- to propagate upwards to the LEX of the caller (when a property of a
- sp_head needs to "taint" the caller).
+ This method is intended for attributes of a routine which need to
+ propagate upwards to the LEX of the caller.
*/
void propagate_attributes(LEX *lex)
{
+ DBUG_ENTER("sp_head::propagate_attributes");
/*
If this routine needs row-based binary logging, the entire top statement
too (we cannot switch from statement-based to row-based only for this
routine, as in statement-based the top-statement may be binlogged and
the substatements not).
*/
- if (m_flags & BINLOG_ROW_BASED_IF_MIXED)
- lex->set_stmt_unsafe();
+ DBUG_PRINT("info", ("lex->get_stmt_unsafe_flags(): 0x%x",
+ lex->get_stmt_unsafe_flags()));
+ DBUG_PRINT("info", ("sp_head(0x%p=%s)->unsafe_flags: 0x%x",
+ this, name(), unsafe_flags));
+ lex->set_stmt_unsafe_flags(unsafe_flags);
+ DBUG_VOID_RETURN;
}
sp_pcontext *get_parse_context() { return m_pcont; }