pmt: add memory test function and some new functions to libhelper

This commit is contained in:
2025-08-13 10:58:48 +03:00
parent 0bc5f70294
commit bf0df8cc83
7 changed files with 33 additions and 13 deletions

View File

@@ -95,6 +95,8 @@ garbageCollector::~garbageCollector() {
close(fd);
for (const auto &fp : _fps)
fclose(fp);
for (const auto &file: _files)
eraseEntry(file);
}
void garbageCollector::delAfterProgress(char *&_ptr) {
@@ -103,6 +105,9 @@ void garbageCollector::delAfterProgress(char *&_ptr) {
void garbageCollector::delAfterProgress(uint8_t *&_ptr) {
_ptrs_u.push_back(_ptr);
}
void garbageCollector::delFileAfterProgress(const std::string_view path) {
_files.push_back(path);
}
void garbageCollector::closeAfterProgress(const int _fd) {
_fds.push_back(_fd);
}