diff --git a/src/archutils/Common/HidDevice.cpp b/src/archutils/Common/HidDevice.cpp index d13ca4ab35..021b2bba26 100644 --- a/src/archutils/Common/HidDevice.cpp +++ b/src/archutils/Common/HidDevice.cpp @@ -13,7 +13,7 @@ HidDevice::HidDevice(int vid, const std::vector pids, int interfaceNum, boo if (!result) { - LOG->Warn("HidDevice with vendor_id %04x and pids %s - %d not found", vid, GetPidsString(pids).c_str(), interfaceNum); + LOG->Warn("HidDevice with vendor_id %04x and pids %s: %d not found", vid, GetPidsString(pids).c_str(), interfaceNum); } else foundOnce = true; @@ -45,10 +45,10 @@ bool HidDevice::Open(const char* path) { handle = hid_open_path(path); - if(nonBlockingRead) + if (nonBlockingRead) hid_set_nonblocking(handle, 1); - if(handle) + if (handle) LOG->Info("HidDevice %04x:%04x: %d opened by path %s", foundDeviceInfo.vid, foundDeviceInfo.pid, foundDeviceInfo.interfaceNum, foundDeviceInfo.path); return handle != nullptr; diff --git a/src/archutils/Common/HidDevice.h b/src/archutils/Common/HidDevice.h index 908611ae67..21950dbc89 100644 --- a/src/archutils/Common/HidDevice.h +++ b/src/archutils/Common/HidDevice.h @@ -21,7 +21,7 @@ static std::vector make_pids(int base_pid, int size) } struct HidDeviceInfo { - char* path{nullptr}; + char* path{ nullptr }; int pid; int vid; int interfaceNum; @@ -31,7 +31,7 @@ class HidDevice { private: HidDeviceInfo foundDeviceInfo{}; - hid_device* handle{nullptr}; + hid_device* handle{ nullptr }; static const RString GetPidsString(const std::vector pids);