Skip to content

Commit c0abf2e

Browse files
Tor Didriksendahlerlend
authored andcommitted
BUG#32288105: MYSQL CRASHES IMMEDIATELY AFTER SELECTING FROM
INFORMATION_SCHEMA Post-push fix for ASAN failure: ==117066==ERROR: AddressSanitizer: stack-use-after-scope on address .. Move tmp_name out to a scope where it is still alive when used later. Change-Id: Ic87b9808d0e2d0dec3a7437109516b67940150b2
1 parent 64e226c commit c0abf2e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

storage/innobase/dict/dict0dd.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,6 +448,7 @@ int dd_table_open_on_dd_obj(THD *thd, dd::cache::Dictionary_client *client,
448448
}
449449

450450
const char *table_name = tbl_name;
451+
char tmp_name[FN_REFLEN + 1];
451452
if (!tbl_name) {
452453
dd::Schema *schema;
453454
error = client->acquire_uncached<dd::Schema>(dd_table.schema_id(), &schema);
@@ -456,7 +457,6 @@ int dd_table_open_on_dd_obj(THD *thd, dd::cache::Dictionary_client *client,
456457
}
457458

458459
bool truncated;
459-
char tmp_name[FN_REFLEN + 1];
460460
build_table_filename(tmp_name, sizeof(tmp_name) - 1, schema->name().c_str(),
461461
dd_table.name().c_str(), nullptr, 0, &truncated);
462462

0 commit comments

Comments
 (0)