Skip to content

Commit 58b266a

Browse files
florin-popd-lucena
andcommitted
Replace cout with LOGE for logging exceptions.
Co-authored-by: Diogo de Lucena <[email protected]>
1 parent 2b9aa2d commit 58b266a

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Source/LSLInletThread.cpp

+6-6
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,11 @@ bool LSLInletThread::updateBuffer()
6969
}
7070
catch (const std::runtime_error &re)
7171
{
72-
std::cout << "Failed to read data samples with runtime error: " << re.what() << std::endl;
72+
LOGE("Failed to read data samples with runtime error: ", re.what());
7373
}
7474
catch (const std::exception &ex)
7575
{
76-
std::cout << "Failed to read data samples with exception: " << ex.what() << std::endl;
76+
LOGE("Failed to read data samples with runtime exception: ", ex.what());
7777
}
7878

7979
if (multiplexed_samples_read <= 0)
@@ -177,11 +177,11 @@ void LSLInletThread::readMarkers(std::size_t samples_to_read)
177177
}
178178
catch (const std::runtime_error &re)
179179
{
180-
std::cout << "Failed to read markers with runtime error: " << re.what() << std::endl;
180+
LOGE("Failed to read markers with runtime error: ", re.what());
181181
}
182182
catch (const std::exception &ex)
183183
{
184-
std::cout << "Failed to read markers with exception: " << ex.what() << std::endl;
184+
LOGE("Failed to read markers with exception: ", ex.what());
185185
}
186186
}
187187

@@ -407,12 +407,12 @@ bool LSLInletThread::setMarkersMappingPath(std::string filePath)
407407
}
408408
catch (const std::runtime_error &re)
409409
{
410-
std::cout << "Failed to read markers mapping file with runtime error: " << re.what() << std::endl;
410+
LOGE("Failed to read markers mapping file with runtime error: ", re.what());
411411
return false;
412412
}
413413
catch (const std::exception &ex)
414414
{
415-
std::cout << "Failed to read markers mapping file with exception: " << ex.what() << std::endl;
415+
LOGE("Failed to read markers mapping file with runtime exception: ", ex.what());
416416
return false;
417417
}
418418

0 commit comments

Comments
 (0)