Skip to content

Commit

Permalink
Cleanup: Add missing const
Browse files Browse the repository at this point in the history
  • Loading branch information
dr-m committed Oct 6, 2022
1 parent 959ad2f commit 97b0eee
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 13 deletions.
2 changes: 1 addition & 1 deletion storage/innobase/handler/ha_innodb.cc
Expand Up @@ -20169,7 +20169,7 @@ innobase_rename_vc_templ(
for purge thread.
*/

bool innobase_allocate_row_for_vcol(THD *thd, dict_index_t *index,
bool innobase_allocate_row_for_vcol(THD *thd, const dict_index_t *index,
mem_heap_t **heap, TABLE **table,
VCOL_STORAGE *storage)
{
Expand Down
19 changes: 7 additions & 12 deletions storage/innobase/include/row0mysql.h
Expand Up @@ -755,9 +755,8 @@ struct VCOL_STORAGE
@return TRUE malloc failure
*/

bool innobase_allocate_row_for_vcol(
THD * thd,
dict_index_t* index,
bool innobase_allocate_row_for_vcol(THD *thd,
const dict_index_t* index,
mem_heap_t** heap,
TABLE** table,
VCOL_STORAGE* storage);
Expand All @@ -773,17 +772,13 @@ class ib_vcol_row

ib_vcol_row(mem_heap_t *heap) : heap(heap) {}

byte *record(THD *thd, dict_index_t *index, TABLE **table)
byte *record(THD *thd, const dict_index_t *index, TABLE **table)
{
if (!storage.innobase_record)
{
bool ok = innobase_allocate_row_for_vcol(thd, index, &heap, table,
&storage);
if (!ok)
return NULL;
}
if (!storage.innobase_record &&
!innobase_allocate_row_for_vcol(thd, index, &heap, table, &storage))
return nullptr;
return storage.innobase_record;
};
}

~ib_vcol_row()
{
Expand Down

0 comments on commit 97b0eee

Please sign in to comment.