diff options
author | Alexander Nozdrin <alik@sun.com> | 2010-01-21 12:14:34 +0300 |
---|---|---|
committer | Alexander Nozdrin <alik@sun.com> | 2010-01-21 12:14:34 +0300 |
commit | 08bcd2d8f67dcacd36abd2592fa2a59321abe7c2 (patch) | |
tree | 1a7e0403e8ed7b5ae817b8249812184027c9cd68 /sql/sp_head.h | |
parent | b6685d35dcc45e4fc8eca53fa8f6d3315f2e6b89 (diff) | |
parent | 8b7d5366ce40280d634bf56f342342fab9d90287 (diff) | |
download | mariadb-git-08bcd2d8f67dcacd36abd2592fa2a59321abe7c2.tar.gz |
Auto-merge from mysql-next-mr.
Diffstat (limited to 'sql/sp_head.h')
-rw-r--r-- | sql/sp_head.h | 24 |
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; } |