Commit dc1cc4f7 authored by heikki@donna.mysql.fi's avatar heikki@donna.mysql.fi
Browse files

btr0pcur.c Fix a bug in persistent cursor restoration: this could cause...

btr0pcur.c	Fix a bug in persistent cursor restoration: this could cause crashes especially if the buffer pool is small
parent 4e18c236
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -246,6 +246,12 @@ btr_pcur_restore_position(
		&& btr_pcur_is_on_user_rec(cursor, mtr)
		&& (0 == cmp_dtuple_rec(tuple, btr_pcur_get_rec(cursor)))) {

	        /* We have to store the NEW value for the modify clock, since
	        the cursor can now be on a different page! */

	        cursor->modify_clock = buf_frame_get_modify_clock(
				    buf_frame_align(
						    btr_pcur_get_rec(cursor)));
		mem_heap_free(heap);

		return(TRUE);