diff options
Diffstat (limited to 'Userland/Applications')
8 files changed, 9 insertions, 3 deletions
diff --git a/Userland/Applications/FontEditor/GlyphEditorWidget.cpp b/Userland/Applications/FontEditor/GlyphEditorWidget.cpp index a36b3586bb..d4877bca4e 100644 --- a/Userland/Applications/FontEditor/GlyphEditorWidget.cpp +++ b/Userland/Applications/FontEditor/GlyphEditorWidget.cpp @@ -11,6 +11,7 @@ #include <LibGUI/Painter.h> #include <LibGfx/BitmapFont.h> #include <LibGfx/Palette.h> +#include <string.h> static int x_offset; static int y_offset; diff --git a/Userland/Applications/HexEditor/HexEditor.cpp b/Userland/Applications/HexEditor/HexEditor.cpp index e4ec9af54e..35dc37f6ec 100644 --- a/Userland/Applications/HexEditor/HexEditor.cpp +++ b/Userland/Applications/HexEditor/HexEditor.cpp @@ -23,6 +23,7 @@ #include <ctype.h> #include <fcntl.h> #include <stdio.h> +#include <string.h> #include <unistd.h> HexEditor::HexEditor() diff --git a/Userland/Applications/PixelPaint/Image.cpp b/Userland/Applications/PixelPaint/Image.cpp index dca4e320e5..25b60c704b 100644 --- a/Userland/Applications/PixelPaint/Image.cpp +++ b/Userland/Applications/PixelPaint/Image.cpp @@ -159,7 +159,7 @@ Result<void, String> Image::write_to_file(const String& file_path) const auto file_or_error = Core::File::open(file_path, (Core::OpenMode)(Core::OpenMode::WriteOnly | Core::OpenMode::Truncate)); if (file_or_error.is_error()) - return String { file_or_error.error().string() }; + return String { strerror(file_or_error.error().code()) }; if (!file_or_error.value()->write(builder.string_view())) return String { file_or_error.value()->error_string() }; diff --git a/Userland/Applications/PixelPaint/PaletteWidget.cpp b/Userland/Applications/PixelPaint/PaletteWidget.cpp index bae64b426c..d5adcf290c 100644 --- a/Userland/Applications/PixelPaint/PaletteWidget.cpp +++ b/Userland/Applications/PixelPaint/PaletteWidget.cpp @@ -15,6 +15,7 @@ #include <LibGUI/ColorPicker.h> #include <LibGUI/MessageBox.h> #include <LibGfx/Palette.h> +#include <string.h> REGISTER_WIDGET(PixelPaint, PaletteWidget); @@ -263,7 +264,7 @@ Result<Vector<Color>, String> PaletteWidget::load_palette_path(String const& fil { auto file_or_error = Core::File::open(file_path, Core::OpenMode::ReadOnly); if (file_or_error.is_error()) - return String { file_or_error.error().string() }; + return String { strerror(file_or_error.error().code()) }; auto& file = *file_or_error.value(); return load_palette_file(file); diff --git a/Userland/Applications/Run/RunWindow.cpp b/Userland/Applications/Run/RunWindow.cpp index 6964ac3be8..96eb30ce35 100644 --- a/Userland/Applications/Run/RunWindow.cpp +++ b/Userland/Applications/Run/RunWindow.cpp @@ -20,6 +20,7 @@ #include <LibGUI/Widget.h> #include <spawn.h> #include <stdio.h> +#include <string.h> #include <sys/wait.h> #include <unistd.h> diff --git a/Userland/Applications/Spreadsheet/ExportDialog.cpp b/Userland/Applications/Spreadsheet/ExportDialog.cpp index 62a82f53be..680d770e66 100644 --- a/Userland/Applications/Spreadsheet/ExportDialog.cpp +++ b/Userland/Applications/Spreadsheet/ExportDialog.cpp @@ -22,6 +22,7 @@ #include <LibGUI/TextBox.h> #include <LibGUI/Wizards/WizardDialog.h> #include <LibGUI/Wizards/WizardPage.h> +#include <string.h> #include <unistd.h> // This is defined in ImportDialog.cpp, we can't include it twice, since the generated symbol is exported. diff --git a/Userland/Applications/Spreadsheet/Readers/Test/TestXSV.cpp b/Userland/Applications/Spreadsheet/Readers/Test/TestXSV.cpp index 5dbe2a5966..0103e4c6c0 100644 --- a/Userland/Applications/Spreadsheet/Readers/Test/TestXSV.cpp +++ b/Userland/Applications/Spreadsheet/Readers/Test/TestXSV.cpp @@ -10,6 +10,7 @@ #include "../XSV.h" #include <AK/ByteBuffer.h> #include <LibCore/File.h> +#include <string.h> TEST_CASE(should_parse_valid_data) { diff --git a/Userland/Applications/Spreadsheet/Workbook.cpp b/Userland/Applications/Spreadsheet/Workbook.cpp index 40c94e12fe..df9b331d4e 100644 --- a/Userland/Applications/Spreadsheet/Workbook.cpp +++ b/Userland/Applications/Spreadsheet/Workbook.cpp @@ -51,7 +51,7 @@ Result<bool, String> Workbook::load(const StringView& filename) sb.append("Failed to open "); sb.append(filename); sb.append(" for reading. Error: "); - sb.append(file_or_error.error().string()); + sb.appendff("{}", file_or_error.error()); return sb.to_string(); } |