mirror of
https://github.com/ByteWelder/Tactility.git
synced 2026-02-18 19:03:16 +00:00
- Moved `file::getlock(path)` from `Tactility` to `TactilityCore` - Changed all existing `file::*` functions to implement locking by default - Removed all manual locking where `file::*` functions were used - When `DevelopmentService` receives a file, it doesn't try to allocate it all in memory. This fixes going out-of-memory on devices without PSRAM. - Fix for TactilityC include
14 lines
257 B
C++
14 lines
257 B
C++
#include <tt_file.h>
|
|
#include <tt_lock_private.h>
|
|
#include <Tactility/file/File.h>
|
|
|
|
extern "C" {
|
|
|
|
LockHandle tt_lock_alloc_for_file(const char* path) {
|
|
auto lock = tt::file::getLock(path);
|
|
auto holder = new LockHolder(lock);
|
|
return holder;
|
|
}
|
|
|
|
}
|