Skip to content

Commit

Permalink
Use portable PRIu64 macro instead of %lu for uint64_t
Browse files Browse the repository at this point in the history
  • Loading branch information
jeongyunl committed Dec 21, 2023
1 parent 2e8552e commit 2849da4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion examples/ulog_info.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
****************************************************************************/

#include <algorithm>
#include <cinttypes>
#include <fstream>
#include <iostream>
#include <numeric>
Expand Down Expand Up @@ -108,7 +109,7 @@ int main(int argc, char** argv)
if (logging.hasTag()) {
tag_str = std::to_string(logging.tag()) + " ";
}
printf(" %s<%s> %lu %s\n", tag_str.c_str(), logging.logLevelStr().c_str(), logging.timestamp(),
printf(" %s<%s> %" PRIu64 " %s\n", tag_str.c_str(), logging.logLevelStr().c_str(), logging.timestamp(),
logging.message().c_str());
}

Expand Down

0 comments on commit 2849da4

Please sign in to comment.