From c0472cc382c9ae2196fef8a6c40c93a8022d68ac Mon Sep 17 00:00:00 2001 From: Dmitry Perchanov Date: Tue, 28 May 2024 17:06:52 +0300 Subject: [PATCH] fw-update: vc compilation issue try2 Signed-off-by: Dmitry Perchanov --- src/fw-update/fw-update-device.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/fw-update/fw-update-device.cpp b/src/fw-update/fw-update-device.cpp index fb1cf327e4c..3ab2c5652db 100644 --- a/src/fw-update/fw-update-device.cpp +++ b/src/fw-update/fw-update-device.cpp @@ -15,7 +15,7 @@ #include #include #include -#include +#include #define DEFAULT_TIMEOUT 100 #define FW_UPDATE_INTERFACE_NUMBER 0 @@ -189,7 +189,7 @@ namespace librealsense , _product_line( product_line ) , _serial_number( mipi_device->get_info().serial_number ) { - std::ifstream fw_path_in_device(_physical_port); + std::ifstream fw_path_in_device(_physical_port.c_str()); if (!fw_path_in_device) { throw std::runtime_error("Firmware Update failed - wrong path or permissions missing"); @@ -306,7 +306,7 @@ namespace librealsense throw librealsense::invalid_value_exception("Device: " + get_serial_number() + " failed to update firmware\nImage is unsupported for this device or corrupted"); // Write signed firmware to appropriate file descriptor - std::ofstream fw_path_in_device(_physical_port, std::ios::binary); + std::ofstream fw_path_in_device(_physical_port.c_str(), std::ios::binary); if (!fw_path_in_device) { throw std::runtime_error("Firmware Update failed - wrong path or permissions missing");