furi_check - a new way to asserting (#204)
* hal-related task_is_isr_context function * furi_check implementation * change application to use furi_check * add second level of assertion * add TODO about ISR context * Applications: refactor furi_check and furi_assert. * Apploader: propwer widget usage. Menu: check on furi resource request. * refactor furi_check Co-authored-by: Aleksandr Kutuzov <aku@plooks.com> Co-authored-by: coreglitch <mail@s3f.ru>
This commit is contained in:
@@ -49,7 +49,7 @@ static inline void* acquire_mutex_block(ValueMutex* valuemutex) {
|
||||
#define with_value_mutex(value_mutex, function_body) \
|
||||
{ \
|
||||
void* p = acquire_mutex_block(value_mutex); \
|
||||
assert(p); \
|
||||
furi_check(p); \
|
||||
({ void __fn__ function_body __fn__; })(p); \
|
||||
release_mutex(value_mutex, p); \
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user