Browse Source

Fix sdcard logging when crypto is used but algorithm is set to NONE

If the board supports encrypting logfiles, but the parameter SDCARD_ALGORITHM is set to NONE,
the log should be written to the sdcard in plaintext format. This fixes a bug which caused
logger to hang in mutex instead.

Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
master
Jukka Laitinen 3 years ago committed by Daniel Agar
parent
commit
a2dc6e63cf
  1. 1
      src/modules/logger/log_writer_file.cpp

1
src/modules/logger/log_writer_file.cpp

@ -86,6 +86,7 @@ LogWriterFile::~LogWriterFile()
bool LogWriterFile::init_logfile_encryption(const char *filename) bool LogWriterFile::init_logfile_encryption(const char *filename)
{ {
if (_algorithm == CRYPTO_NONE) { if (_algorithm == CRYPTO_NONE) {
_min_blocksize = 1;
return true; return true;
} }

Loading…
Cancel
Save