mirror of
https://github.com/ByteWelder/Tactility.git
synced 2026-02-18 02:43:15 +00:00
Merge develop into main (#322)
- Fix crash in TactilityC - Improve MAX_TICKS implementation (and renamed to TT_MAX_TICKS)
This commit is contained in:
parent
457c21ffd8
commit
63866fb371
@ -22,7 +22,7 @@ public:
|
||||
tt_hal_display_driver_free(handle);
|
||||
}
|
||||
|
||||
bool lock(TickType timeout = MAX_TICKS) const {
|
||||
bool lock(TickType timeout = TT_MAX_TICKS) const {
|
||||
return tt_hal_display_driver_lock(handle, timeout);
|
||||
}
|
||||
|
||||
|
||||
@ -8,7 +8,7 @@ extern "C" {
|
||||
|
||||
typedef unsigned long TickType;
|
||||
|
||||
#define MAX_TICKS INT32_MAX
|
||||
#define TT_MAX_TICKS ((TickType)(~(TickType)0))
|
||||
|
||||
/**
|
||||
* Stall the current task for the specified amount of time.
|
||||
|
||||
@ -41,7 +41,7 @@ void tt_app_get_data_directory(AppPathsHandle handle, char* buffer, size_t* size
|
||||
auto data_path = paths->getDataDirectory();
|
||||
auto expected_length = data_path.length() + 1;
|
||||
if (*size < expected_length) {
|
||||
TT_LOG_E(TAG, "Path buffer not large enough (%d < %d)", size, expected_length);
|
||||
TT_LOG_E(TAG, "Path buffer not large enough (%d < %d)", *size, expected_length);
|
||||
*size = 0;
|
||||
buffer[0] = 0;
|
||||
return;
|
||||
@ -59,7 +59,7 @@ void tt_app_get_data_directory_lvgl(AppPathsHandle handle, char* buffer, size_t*
|
||||
auto data_path = paths->getDataDirectoryLvgl();
|
||||
auto expected_length = data_path.length() + 1;
|
||||
if (*size < expected_length) {
|
||||
TT_LOG_E(TAG, "Path buffer not large enough (%d < %d)", size, expected_length);
|
||||
TT_LOG_E(TAG, "Path buffer not large enough (%d < %d)", *size, expected_length);
|
||||
*size = 0;
|
||||
buffer[0] = 0;
|
||||
return;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user