core: avoid the use of pop_back on empty string

fixes #222
This commit is contained in:
Vaxry 2024-12-15 21:58:11 +00:00
parent b17d32fdd2
commit 4d5b68b7ad

View file

@ -580,7 +580,8 @@ void CHyprpaper::renderWallpaperForMonitor(SMonitor* pMonitor) {
if (*PRENDERSPLASH && getenv("HYPRLAND_INSTANCE_SIGNATURE")) {
auto SPLASH = execAndGet("hyprctl splash");
SPLASH.pop_back();
if (!SPLASH.empty())
SPLASH.pop_back();
Debug::log(LOG, "Rendering splash: {}", SPLASH);