fsfw/hal/src/fsfw_hal/linux/utility.cpp

14 lines
311 B
C++
Raw Normal View History

2021-08-02 20:58:56 +02:00
#include "fsfw_hal/linux/utility.h"
2021-07-15 19:06:40 +02:00
#include <cerrno>
#include <cstring>
2021-07-13 19:19:25 +02:00
2022-05-09 00:09:13 +02:00
#include "fsfw/serviceinterface.h"
2022-02-02 10:29:30 +01:00
2021-07-13 19:19:25 +02:00
void utility::handleIoctlError(const char* const customPrintout) {
2022-02-02 10:29:30 +01:00
if (customPrintout != nullptr) {
2022-05-09 00:09:13 +02:00
FSFW_LOGW(customPrintout);
2022-02-02 10:29:30 +01:00
}
2022-05-09 00:09:13 +02:00
FSFW_LOGW("Error code {} | {}\n", errno, strerror(errno));
2021-07-13 19:19:25 +02:00
}