summaryrefslogtreecommitdiff
path: root/Userland/Applications/FontEditor/main.cpp
diff options
context:
space:
mode:
authorthankyouverycool <66646555+thankyouverycool@users.noreply.github.com>2023-05-10 17:00:50 -0400
committerAndreas Kling <kling@serenityos.org>2023-05-13 12:53:49 +0200
commit6212e5b1f0ec9cd242dbf1f434f2f3d6b73a5bff (patch)
treecc37c1595654cef78bd6b8cdb60f9ffdf2133c0c /Userland/Applications/FontEditor/main.cpp
parentea8bcb2f30bd2ab020a56368484ba7c0401fc398 (diff)
downloadserenity-6212e5b1f0ec9cd242dbf1f434f2f3d6b73a5bff.zip
FontEditor: Don't crash on missing icons
Instead of crashing on failed icon loading with TRY(), let's report missing but non-critical resources in detail and gracefully move on.
Diffstat (limited to 'Userland/Applications/FontEditor/main.cpp')
-rw-r--r--Userland/Applications/FontEditor/main.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/Userland/Applications/FontEditor/main.cpp b/Userland/Applications/FontEditor/main.cpp
index 22bd4a1297..822148dc06 100644
--- a/Userland/Applications/FontEditor/main.cpp
+++ b/Userland/Applications/FontEditor/main.cpp
@@ -23,6 +23,8 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
auto app = TRY(GUI::Application::create(arguments));
+ FontEditor::g_resources = FontEditor::Resources::create();
+
TRY(Desktop::Launcher::add_allowed_handler_with_only_specific_urls("/bin/Help", { URL::create_with_file_scheme("/usr/share/man/man1/Applications/FontEditor.md") }));
TRY(Desktop::Launcher::seal_allowlist());