From beb23867f8cfd5bc0c58b8044de3433b40c2b3e5 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Fri, 3 Feb 2023 14:42:41 -0500 Subject: Suppress/fix new warnings in clang-tidy 15 --- src/main.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'src/main.cpp') diff --git a/src/main.cpp b/src/main.cpp index 568ebca..6d09fe4 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -23,7 +23,8 @@ #if USE_GETTEXT # include -# include + +# include #endif #include @@ -100,7 +101,10 @@ main(int argc, char** argv) #endif #if USE_GETTEXT - setlocale(LC_ALL, ""); + if (!setlocale(LC_ALL, "")) { + std::cerr << "patchage: failed to set locale\n"; + } + bindtextdomain("patchage", PATCHAGE_LOCALE_DIR); bind_textdomain_codeset("patchage", "UTF-8"); textdomain("patchage"); @@ -109,7 +113,7 @@ main(int argc, char** argv) try { Glib::thread_init(); - Gtk::Main app(argc, argv); + const Gtk::Main app(argc, argv); ++argv; --argc; -- cgit v1.2.1