[sanitizer] Fix arg types of internal functions

They didn't match sanitizer_common for 32bit.
This commit is contained in:
Vitaly Buka 2022-04-11 17:25:08 -07:00
parent 5a5034d508
commit b87b642aa6
2 changed files with 4 additions and 2 deletions

View File

@ -10,6 +10,7 @@
//
//===----------------------------------------------------------------------===//
#include <inttypes.h>
#include <stdio.h>
#include <string>
@ -41,7 +42,7 @@ static llvm::symbolize::PrinterConfig getDefaultPrinterConfig() {
}
namespace __sanitizer {
int internal_snprintf(char *buffer, unsigned long length, const char *format,
int internal_snprintf(char *buffer, uintptr_t length, const char *format,
...);
} // namespace __sanitizer

View File

@ -13,6 +13,7 @@
#include <dlfcn.h>
#include <errno.h>
#include <fcntl.h>
#include <inttypes.h>
#include <stdarg.h>
#include <stdio.h>
#include <unistd.h>
@ -31,7 +32,7 @@ unsigned long internal_mmap(void *addr, unsigned long length, int prot,
int flags, int fd, unsigned long long offset);
void *internal_memcpy(void *dest, const void *src, unsigned long n);
// Used to propagate errno.
bool internal_iserror(unsigned long retval, int *rverrno = 0);
bool internal_iserror(uintptr_t retval, int *rverrno = 0);
} // namespace __sanitizer
namespace {