This commit is contained in:
Cloud Wu
2025-06-15 10:49:56 +08:00
parent 4ff4db3161
commit e21604783a

View File

@@ -59,6 +59,8 @@ int luaS_eqshrstr (TString *a, TString *b) {
void luaS_share (TString *ts) {
if (ts == NULL || isshared(ts))
return;
if (ts->tt == LUA_VLNGSTR)
luaS_hashlongstr(ts);
makeshared(ts);
ts->id = ATOM_FDEC(&STRID)-1;
}