You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a good start, but we should go further and periodically clean up these tables (or have some smarter algorithm). It's noteworthy, that weak_ptrs to shared_ptrs allocated with make_shared prevent the underlying storage from being freed when all shared_ptrs go out of scope (the destructor still runs, but the storage is only cleaned up later, see blog).
Currently, we have some mutable
static
caches (mainly for emotes/images).chatterino2/src/providers/ffz/FfzEmotes.cpp
Line 62 in 4d9ea37
chatterino2/src/providers/bttv/BttvEmotes.cpp
Line 54 in 4d9ea37
chatterino2/src/providers/seventv/SeventvEmotes.cpp
Line 51 in 4d9ea37
chatterino2/src/messages/Image.cpp
Line 288 in 4d9ea37
chatterino2/src/providers/twitch/TwitchEmotes.hpp
Lines 99 to 100 in 4d9ea37
This is a good start, but we should go further and periodically clean up these tables (or have some smarter algorithm). It's noteworthy, that
weak_ptr
s toshared_ptr
s allocated withmake_shared
prevent the underlying storage from being freed when allshared_ptr
s go out of scope (the destructor still runs, but the storage is only cleaned up later, see blog).Loosely related to #2732.
The text was updated successfully, but these errors were encountered: