mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-22 05:03:34 +08:00
Small fixes for debug macros
Fixed print format for __LINE__ to %d Fixed if/else that breaks with the debug macro expansion. The if/else needs to use braces to allow macro expansion. Signed-off-by: Mark Charlebois <charlebm@gmail.com>
This commit is contained in:
@@ -227,10 +227,12 @@ void px4_task_exit(int ret)
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (i>=PX4_MAX_TASKS)
|
||||
if (i>=PX4_MAX_TASKS) {
|
||||
PX4_ERR("px4_task_exit: self task not found!");
|
||||
else
|
||||
}
|
||||
else {
|
||||
PX4_DBG("px4_task_exit: %s", taskmap[i].name.c_str());
|
||||
}
|
||||
|
||||
pthread_exit((void *)(unsigned long)ret);
|
||||
}
|
||||
|
||||
@@ -85,9 +85,6 @@ struct wqueue_s g_work[NWORKERS];
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#define USEC_TO_TICKS(x) (uint32_t)((x)/1000ull)
|
||||
#define TICKS_TO_USEC(x) ((x)*1000ull)
|
||||
|
||||
static void work_process(FAR struct wqueue_s *wqueue)
|
||||
{
|
||||
volatile FAR struct work_s *work;
|
||||
|
||||
Reference in New Issue
Block a user