mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-28 10:46:33 +08:00
logger: move writer_thread variable into function (never accessed outside)
This commit is contained in:
@@ -83,7 +83,6 @@ using namespace px4::logger;
|
|||||||
|
|
||||||
static Logger *logger_ptr = nullptr;
|
static Logger *logger_ptr = nullptr;
|
||||||
static int logger_task = -1;
|
static int logger_task = -1;
|
||||||
static pthread_t writer_thread;
|
|
||||||
|
|
||||||
/* This is used to schedule work for the logger (periodic scan for updated topics) */
|
/* This is used to schedule work for the logger (periodic scan for updated topics) */
|
||||||
static void timer_callback(void *arg)
|
static void timer_callback(void *arg)
|
||||||
@@ -638,6 +637,7 @@ void Logger::run()
|
|||||||
PX4_ERR("init of writer failed (alloc failed)");
|
PX4_ERR("init of writer failed (alloc failed)");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
pthread_t writer_thread;
|
||||||
|
|
||||||
int ret = _writer.thread_start(writer_thread);
|
int ret = _writer.thread_start(writer_thread);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user