compat: improve non glibc support

This commit is contained in:
Lemmy
2026-05-09 23:56:46 -04:00
parent b113e3b60d
commit afc7f7f58a
4 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -268,7 +268,9 @@ void Application::run() {
runStartupPhase("telemetry enqueue",
[this]() { m_telemetryService.maybeSend(m_configService, m_httpClient, m_wayland); });
#ifdef __GLIBC__
runStartupPhase("malloc_trim", []() { malloc_trim(0); });
#endif
m_trayInitTimer.start(std::chrono::milliseconds(500), [this]() { startTrayService(); });
m_polkitInitTimer.start(std::chrono::milliseconds(0), [this]() { syncPolkitAgent(); });
@@ -987,8 +989,6 @@ void Application::initUi() {
m_fileDialogPopup.requestLayout();
});
m_configService.addReloadCallback([]() { malloc_trim(0); });
m_timeService.setTickSecondCallback([this]() {
m_wallpaper.onSecondTick();
if (m_lockScreen.isActive()) {
+1
View File
@@ -4,6 +4,7 @@
#include <cstdlib>
#include <cstring>
#include <sys/socket.h>
#include <sys/time.h>
#include <sys/un.h>
#include <unistd.h>
+1
View File
@@ -6,6 +6,7 @@
#include <cstdlib>
#include <cstring>
#include <sys/socket.h>
#include <sys/time.h>
#include <sys/un.h>
#include <unistd.h>
-2
View File
@@ -690,8 +690,6 @@ void PanelManager::destroyPanel() {
if (m_platform != nullptr) {
m_platform->stopKeyRepeat();
}
malloc_trim(0);
}
void PanelManager::togglePanel(const std::string& panelId, PanelOpenRequest request) {