List:Commits« Previous MessageNext Message »
From:marko.makela Date:May 31 2011 8:24am
Subject:bzr push into mysql-trunk branch (marko.makela:3131 to 3132)
View as plain text  
 3132 Marko Mäkelä	2011-05-31 [merge]
      Merge mysql-5.5 to mysql-trunk.

    modified:
      storage/innobase/include/mtr0mtr.ic
      storage/innobase/mtr/mtr0mtr.c
 3131 Davi Arnaut	2011-05-30 [merge]
      Merge of mysql-5.5 into mysql-trunk.

    modified:
      mysql-test/r/query_cache_debug.result
      mysql-test/t/query_cache_debug.test
=== modified file 'storage/innobase/include/mtr0mtr.ic'
--- a/storage/innobase/include/mtr0mtr.ic	revid:davi.arnaut@stripped
+++ b/storage/innobase/include/mtr0mtr.ic	revid:marko.makela@stripped
@@ -47,6 +47,8 @@ mtr_start(
 /*======*/
 	mtr_t*	mtr)	/*!< out: mini-transaction */
 {
+	UNIV_MEM_INVALID(mtr, sizeof *mtr);
+
 	dyn_array_create(&(mtr->memo));
 	dyn_array_create(&(mtr->log));
 

=== modified file 'storage/innobase/mtr/mtr0mtr.c'
--- a/storage/innobase/mtr/mtr0mtr.c	revid:davi.arnaut@stripped
+++ b/storage/innobase/mtr/mtr0mtr.c	revid:marko.makela@oracle.com-20110531081827-mkqxrlx0ilddhc7m
@@ -296,9 +296,20 @@ mtr_commit(
 	mtr_memo_pop_all(mtr);
 #endif /* !UNIV_HOTBACKUP */
 
-	ut_d(mtr->state = MTR_COMMITTED);
 	dyn_array_free(&(mtr->memo));
 	dyn_array_free(&(mtr->log));
+#ifdef UNIV_DEBUG_VALGRIND
+	/* Declare everything uninitialized except
+	mtr->start_lsn, mtr->end_lsn and mtr->state. */
+	{
+		lsn_t	start_lsn	= mtr->start_lsn;
+		lsn_t	end_lsn		= mtr->end_lsn;
+		UNIV_MEM_INVALID(mtr, sizeof *mtr);
+		mtr->start_lsn = start_lsn;
+		mtr->end_lsn = end_lsn;
+	}
+#endif /* UNIV_DEBUG_VALGRIND */
+	ut_d(mtr->state = MTR_COMMITTED);
 }
 
 #ifndef UNIV_HOTBACKUP

Attachment: [text/bzr-bundle] bzr/marko.makela@oracle.com-20110531081827-mkqxrlx0ilddhc7m.bundle
Thread
bzr push into mysql-trunk branch (marko.makela:3131 to 3132) marko.makela31 May