diff options
Diffstat (limited to 'Userland/Libraries')
-rw-r--r-- | Userland/Libraries/LibGUI/CommonLocationsProvider.cpp | 2 | ||||
-rw-r--r-- | Userland/Libraries/LibGUI/JsonArrayModel.cpp | 8 | ||||
-rw-r--r-- | Userland/Libraries/LibKeyboard/CharacterMapFile.cpp | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/Userland/Libraries/LibGUI/CommonLocationsProvider.cpp b/Userland/Libraries/LibGUI/CommonLocationsProvider.cpp index 808d2d13b7..fd1db73cf9 100644 --- a/Userland/Libraries/LibGUI/CommonLocationsProvider.cpp +++ b/Userland/Libraries/LibGUI/CommonLocationsProvider.cpp @@ -58,7 +58,7 @@ void CommonLocationsProvider::load_from_json(const String& json_path) s_common_locations.clear(); auto contents = json.value().as_array(); - for (auto i = 0; i < contents.size(); ++i) { + for (size_t i = 0; i < contents.size(); ++i) { auto entry_value = contents.at(i); if (!entry_value.is_object()) continue; diff --git a/Userland/Libraries/LibGUI/JsonArrayModel.cpp b/Userland/Libraries/LibGUI/JsonArrayModel.cpp index 601faef990..f294083f14 100644 --- a/Userland/Libraries/LibGUI/JsonArrayModel.cpp +++ b/Userland/Libraries/LibGUI/JsonArrayModel.cpp @@ -59,7 +59,7 @@ bool JsonArrayModel::set(int row, Vector<JsonValue>&& values) { VERIFY(values.size() == m_fields.size()); - if (row >= m_array.size()) + if ((size_t)row >= m_array.size()) return false; JsonObject obj; @@ -76,12 +76,12 @@ bool JsonArrayModel::set(int row, Vector<JsonValue>&& values) bool JsonArrayModel::remove(int row) { - if (row >= m_array.size()) + if ((size_t)row >= m_array.size()) return false; JsonArray new_array; - for (int i = 0; i < m_array.size(); ++i) - if (i != row) + for (size_t i = 0; i < m_array.size(); ++i) + if (i != (size_t)row) new_array.append(m_array.at(i)); m_array = new_array; diff --git a/Userland/Libraries/LibKeyboard/CharacterMapFile.cpp b/Userland/Libraries/LibKeyboard/CharacterMapFile.cpp index 362b3a5f21..9add21aac9 100644 --- a/Userland/Libraries/LibKeyboard/CharacterMapFile.cpp +++ b/Userland/Libraries/LibKeyboard/CharacterMapFile.cpp @@ -74,7 +74,7 @@ Vector<u32> CharacterMapFile::read_map(const JsonObject& json, const String& nam buffer.resize(CHAR_MAP_SIZE); auto map_arr = json.get(name).as_array(); - for (int i = 0; i < map_arr.size(); i++) { + for (size_t i = 0; i < map_arr.size(); i++) { auto key_value = map_arr.at(i).as_string(); if (key_value.length() == 0) { buffer[i] = 0; |