diff --git a/src/ds5/ds5-device.cpp b/src/ds5/ds5-device.cpp index 75bc81d5a0..6490c32dce 100644 --- a/src/ds5/ds5-device.cpp +++ b/src/ds5/ds5-device.cpp @@ -190,7 +190,7 @@ namespace librealsense sector_count += first_sector; - for (size_t sector_index = first_sector; sector_index < sector_count; sector_index++) + for (int sector_index = first_sector; sector_index < sector_count; sector_index++) { command cmdFES(ds::FES); cmdFES.require_response = false; @@ -222,7 +222,7 @@ namespace librealsense update_progress_callback_ptr callback, float continue_from, float ratio) { auto first_table_offset = fs.tables.front().offset; - float total_size = fs.app_size + tables_size; + float total_size = float(fs.app_size + tables_size); float app_ratio = fs.app_size / total_size * ratio; float tables_ratio = tables_size / total_size * ratio; @@ -240,7 +240,7 @@ namespace librealsense // update read-write section auto first_table_offset = flash_image_info.read_write_section.tables.front().offset; auto tables_size = flash_image_info.header.read_write_start_address + flash_image_info.header.read_write_size - first_table_offset; - update_section(hwm, merged_image, flash_image_info.read_write_section, tables_size, callback, 0, update_mode == RS2_UNSIGNED_UPDATE_MODE_READ_ONLY ? 0.5 : 1.0); + update_section(hwm, merged_image, flash_image_info.read_write_section, tables_size, callback, 0, update_mode == RS2_UNSIGNED_UPDATE_MODE_READ_ONLY ? 0.5f : 1.0f); if (update_mode == RS2_UNSIGNED_UPDATE_MODE_READ_ONLY) { diff --git a/src/winusb/enumerator-winusb.cpp b/src/winusb/enumerator-winusb.cpp index b1f426a089..4cab924031 100644 --- a/src/winusb/enumerator-winusb.cpp +++ b/src/winusb/enumerator-winusb.cpp @@ -57,7 +57,7 @@ namespace librealsense cr = CM_Get_Device_Interface_List((LPGUID)&guid, NULL, device_list.data(), length, CM_GET_DEVICE_INTERFACE_LIST_PRESENT); - int offset = 0; + size_t offset = 0; while (offset < length) { auto str = std::wstring((device_list.data() + offset));