Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/server/frontend_wayland/foreign_toplevel_manager_v1.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -579,9 +579,9 @@ void mf::GDesktopFileCache::refresh_app_cache()

// It is likely that [id] ends in a .desktop suffix. If that's the case, we will strip
// it out since that isn't useful in this context.
const char* const DESKTOP_PREFIX = ".desktop";
if (id.ends_with(DESKTOP_PREFIX))
id.erase(id.length() - strlen(DESKTOP_PREFIX));
const char* const desktop_suffix = ".desktop";
if (id.ends_with(desktop_suffix))
id.erase(id.length() - strlen(desktop_suffix));

std::shared_ptr<DesktopFile> file = std::make_shared<DesktopFile>(id.c_str(), wm_class, exec);
if (g_app_info_should_show(app_info))
Expand Down