1. 14 Jan, 2020 1 commit
  2. 07 Jan, 2020 2 commits
    • Marc Gonzalez's avatar
      Widen STRNCATF temporary buffer · 20a1942e
      Marc Gonzalez authored
      The temporary buffer used in STRNCATF is too small for a few callers,
      which could lead to truncated output in some situations.
      Signed-off-by: Marc Gonzalez's avatarMarc Gonzalez <marc.w.gonzalez@free.fr>
      Signed-off-by: Marvin Scholz's avatarMarvin Scholz <epirat07@gmail.com>
      20a1942e
    • Marc Gonzalez's avatar
      Use appropriate printf format specifier macro · a80b8853
      Marc Gonzalez authored
      On some platforms, uint64_t and unsigned long long are not equivalent.
      
      src/processor/stackwalk_fmt_json.cc: In function 'std::__cxx11::string google_breakpad::{anonymous}::ToHex(uint64_t)':
      src/processor/stackwalk_fmt_json.cc:74:34: error: format '%llx' expects argument of type 'long long unsigned int', but argument 3 has type 'uint64_t {aka long unsigned int}' [-Werror=format=]
         sprintf(buffer, "0x%llx", value);
                                        ^
      src/processor/stackwalk_fmt_json.cc: In function 'std::__cxx11::string google_breakpad::{anonymous}::ToInt(uint64_t)':
      src/processor/stackwalk_fmt_json.cc:80:32: error: format '%llu' expects argument of type 'long long unsigned int', but argument 3 has type 'uint64_t {aka long unsigned int}' [-Werror=format=]
         sprintf(buffer, "%llu", value);
                                      ^
      src/processor/stackwalk_fmt_json.cc: In function 'void google_breakpad::{anonymous}::AddRegister(Json::Value&, const char*, uint64_t)':
      src/processor/stackwalk_fmt_json.cc:164:48: error: format '%llx' expects argument of type 'long long unsigned int', but argument 4 has type 'uint64_t {aka long unsigned int}' [-Werror=format=]
         snprintf(buf, sizeof(buf), "0x%016llx", value);
                                                      ^
      
      Fix the above warnings by using PRIu64 and PRIx64.
      Signed-off-by: Marc Gonzalez's avatarMarc Gonzalez <marc.w.gonzalez@free.fr>
      Signed-off-by: Marvin Scholz's avatarMarvin Scholz <epirat07@gmail.com>
      a80b8853
  3. 15 Dec, 2018 37 commits