List:Commits« Previous MessageNext Message »
From:marko.makela Date:May 23 2012 8:09pm
Subject:bzr push into mysql-trunk-wl6255 branch (marko.makela:3858 to 3859)
View as plain text  
 3859 Marko Mäkelä	2012-05-23
      row_rec_to_index_entry(): Make offsets const,
      which it is except in debug builds.

    modified:
      storage/innobase/include/row0row.h
      storage/innobase/row/row0row.cc
 3858 Marko Mäkelä	2012-05-23
      Simplify rec_offs_make_valid() calls.

    modified:
      storage/innobase/api/api0api.cc
      storage/innobase/btr/btr0cur.cc
      storage/innobase/row/row0row.cc
=== modified file 'storage/innobase/include/row0row.h'
--- a/storage/innobase/include/row0row.h	revid:marko.makela@strippedjx2rxt43xum5
+++ b/storage/innobase/include/row0row.h	revid:marko.makela@strippedz
@@ -189,7 +189,7 @@ row_rec_to_index_entry(
 					s-latched and the latch held
 					as long as the dtuple is used! */
 	const dict_index_t*	index,	/*!< in: index */
-	ulint*			offsets,/*!< in/out: rec_get_offsets(rec) */
+	const ulint*		offsets,/*!< in/out: rec_get_offsets(rec) */
 	ulint*			n_ext,	/*!< out: number of externally
 					stored columns */
 	mem_heap_t*		heap)	/*!< in: memory heap from which

=== modified file 'storage/innobase/row/row0row.cc'
--- a/storage/innobase/row/row0row.cc	revid:marko.makela@stripped
+++ b/storage/innobase/row/row0row.cc	revid:marko.makela@oracle.com-20120523200825-1b24wboxme77f0gz
@@ -435,7 +435,7 @@ row_rec_to_index_entry(
 					s-latched and the latch held
 					as long as the dtuple is used! */
 	const dict_index_t*	index,	/*!< in: index */
-	ulint*			offsets,/*!< in/out: rec_get_offsets(rec) */
+	const ulint*		offsets,/*!< in: rec_get_offsets(rec) */
 	ulint*			n_ext,	/*!< out: number of externally
 					stored columns */
 	mem_heap_t*		heap)	/*!< in: memory heap from which
@@ -461,10 +461,10 @@ row_rec_to_index_entry(
 		copy_rec = rec;
 	}
 
-	rec_offs_make_valid(copy_rec, index, offsets);
+	rec_offs_make_valid(copy_rec, index, const_cast<ulint*>(offsets));
 	entry = row_rec_to_index_entry_low(
 		copy_rec, index, offsets, n_ext, heap);
-	rec_offs_make_valid(rec, index, offsets);
+	rec_offs_make_valid(rec, index, const_cast<ulint*>(offsets));
 
 	dtuple_set_info_bits(entry,
 			     rec_get_info_bits(rec, rec_offs_comp(offsets)));

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-trunk-wl6255 branch (marko.makela:3858 to 3859) marko.makela24 May