[bugfix] Avoid potential crash when closing applications in lipstick