Lower CPU usage while finding devices on Linux

pull/13/head
Paul Hollinsky 2019-04-17 16:50:40 -04:00
parent 37b83e0506
commit 4588024ed0
1 changed files with 1 additions and 1 deletions

View File

@ -13,7 +13,7 @@ std::vector<std::tuple<int, std::string>> FTDI::handles;
std::vector<neodevice_t> FTDI::FindByProduct(int product) {
constexpr size_t deviceSerialBufferLength = sizeof(device.serial);
std::vector<neodevice_t> found;
FTDIContext context;
static FTDIContext context;
std::pair<int, std::vector<std::string>> result = context.findDevices(product);
if(result.first < 0)