Skip to content

Commit

Permalink
Use 0-padding for i386 and arm print format specifiers
Browse files Browse the repository at this point in the history
Summary:
This is used for the other architectures in print_address, but is
missing from i386 and arm.

Reviewers: m.ostapenko, spetrovic

Subscribers: aemerson, rengolin, llvm-commits, kubamracek

Differential Revision: https://reviews.llvm.org/D31977

llvm-svn: 300065
  • Loading branch information
fjricci committed Apr 12, 2017
1 parent 4707015 commit f518c75
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion compiler-rt/test/sanitizer_common/print_address.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ void print_address(const char *str, int n, ...) {
// match to the format used in the diagnotic message.
fprintf(stderr, "0x%012lx ", (unsigned long) p);
#elif defined(__i386__) || defined(__arm__)
fprintf(stderr, "0x%8lx ", (unsigned long) p);
fprintf(stderr, "0x%08lx ", (unsigned long) p);
#elif defined(__mips64)
fprintf(stderr, "0x%010lx ", (unsigned long) p);
#endif
Expand Down

0 comments on commit f518c75

Please sign in to comment.