Browse Source

MIME-16: wrap the log output of possibly NULL strings.

master
roker 11 months ago
parent
commit
f04bd35df9
2 changed files with 2 additions and 1 deletions
  1. +1
    -1
      src/header_generator.cc
  2. +1
    -0
      src/pEpMIME_internal.hh

+ 1
- 1
src/header_generator.cc View File

@ -89,7 +89,7 @@ namespace
void generate(std::string& out, sv header_name, const pEp_identity* id)
{
LOG << "GEN_ID: " << id->username << " | " << id->address << std::endl;
LOG << "GEN_ID: " << NN(id->username) << " | " << NN(id->address) << std::endl;
static BasicRules br;
out += exists(id->username) ? encode_header_if_necessary(br.phrase, header_name, id->username, qp::Word) + " " : std::string() ;


+ 1
- 0
src/pEpMIME_internal.hh View File

@ -37,6 +37,7 @@
#endif // C++17 switch
#define NN(str) ( (str) ? (str) : "(NULL)" )
#ifdef LOG_TO_STDERR
#include <iostream>


Loading…
Cancel
Save