diff --git a/row/row0sel.c b/row/row0sel.c index c236260e531..db9ab87d92b 100644 --- a/row/row0sel.c +++ b/row/row0sel.c @@ -2994,7 +2994,7 @@ row_sel_get_clust_rec_for_mysql( clust_rec, offsets, offset_heap, &old_vers, mtr); - if (err != DB_SUCCESS) { + if (err != DB_SUCCESS || old_vers == NULL) { goto err_exit; }