diff --git a/app/src/main/cpp/GPIOControl.cpp b/app/src/main/cpp/GPIOControl.cpp index e1dfbd5d..4d1e9dcd 100644 --- a/app/src/main/cpp/GPIOControl.cpp +++ b/app/src/main/cpp/GPIOControl.cpp @@ -51,8 +51,15 @@ public: ~GpioDebugLogger() { uint64_t ts = (GetMicroTimeStamp() - m_startTime); - - CreateEmptyFile(m_path + ".leave." + std::to_string(ts)); + if (ts > 1000) + { + CreateEmptyFile(m_path + ".leave." + std::to_string(ts)); + } + else + { + std::string path = m_path + ".enter"; + std::remove(path.c_str()); + } } private: