aboutsummaryrefslogtreecommitdiff
path: root/src/modules/sdlog2/sdlog2.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/sdlog2/sdlog2.c')
-rw-r--r--src/modules/sdlog2/sdlog2.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/modules/sdlog2/sdlog2.c b/src/modules/sdlog2/sdlog2.c
index 32bd422bc..6fc430fc9 100644
--- a/src/modules/sdlog2/sdlog2.c
+++ b/src/modules/sdlog2/sdlog2.c
@@ -484,7 +484,7 @@ void sdlog2_stop_log()
warnx("stop logging.");
mavlink_log_info(mavlink_fd, "[sdlog2] stop logging");
- logging_enabled = true;
+ logging_enabled = false;
logwriter_should_exit = true;
/* wake up write thread one last time */
@@ -828,6 +828,8 @@ int sdlog2_thread_main(int argc, char *argv[])
continue;
}
+ ifds = 1; // Begin from fds[1] again
+
pthread_mutex_lock(&logbuffer_mutex);
/* write time stamp message */