logger: check if we are in replay mode via ENV variable 'replay'

This commit is contained in:
Beat Küng
2016-07-07 12:51:42 +02:00
committed by Lorenz Meier
parent 28ad6066aa
commit 84a1a10006
2 changed files with 15 additions and 4 deletions
+2 -3
View File
@@ -85,7 +85,7 @@ public:
* before starting the logger.
* @param file_name file name of the used log replay file. Will be copied.
*/
static void setReplayFile(const char *file_name);
void setReplayFile(const char *file_name);
/**
* Add a topic to be logged. This must be called before start_log()
@@ -233,8 +233,7 @@ private:
param_t _log_utc_offset;
orb_advert_t _mavlink_log_pub = nullptr;
uint16_t _next_topic_id; ///< id of next subscribed topic
static char *_replay_file_name;
char *_replay_file_name = nullptr;
};
} //namespace logger