File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -134,7 +134,7 @@ void FreeRTOS::Semaphore::give() {
134
134
xSemaphoreGive (m_semaphore);
135
135
}
136
136
// #ifdef ARDUINO_ARCH_ESP32
137
- // FreeRTOS::sleep(10);
137
+ // FreeRTOS::sleep(10);
138
138
// #endif
139
139
140
140
m_owner = std::string (" <N/A>" );
@@ -178,7 +178,7 @@ bool FreeRTOS::Semaphore::take(std::string owner)
178
178
if (m_usePthreads) {
179
179
pthread_mutex_lock (&m_pthread_mutex);
180
180
} else {
181
- rc = ::xSemaphoreTake (m_semaphore, portMAX_DELAY);
181
+ rc = ::xSemaphoreTake (m_semaphore, portMAX_DELAY) == pdTRUE ;
182
182
}
183
183
m_owner = owner;
184
184
if (rc) {
@@ -204,7 +204,7 @@ bool FreeRTOS::Semaphore::take(uint32_t timeoutMs, std::string owner) {
204
204
if (m_usePthreads) {
205
205
assert (false ); // We apparently don't have a timed wait for pthreads.
206
206
} else {
207
- rc = ::xSemaphoreTake (m_semaphore, timeoutMs/ portTICK_PERIOD_MS);
207
+ rc = ::xSemaphoreTake (m_semaphore, timeoutMs / portTICK_PERIOD_MS) == pdTRUE ;
208
208
}
209
209
m_owner = owner;
210
210
if (rc) {
You can’t perform that action at this time.
0 commit comments