[sanitizer] use the right type for sizeof
authorWu, Yingcong <yingcong.wu@intel.com>
Thu, 27 Apr 2023 23:46:42 +0000 (16:46 -0700)
committerVitaly Buka <vitalybuka@google.com>
Thu, 27 Apr 2023 23:56:22 +0000 (16:56 -0700)
commit1a8aab6de5de1a085e6311aa9dcfb85010acba86
tree90cf9a6c87da938d935d532e45a11d9f2e1a7854
parentcc781a4e27fb1128b43feb69ef364ed7110f558e
[sanitizer] use the right type for sizeof

`x_aliases` is an array of string, so to calculate its size, it should
be <size-of-array> times <size-of-element>, which should be
`sizeof(char*)` instead of `sizeof(char**)`.

Reviewed By: vitalybuka

Differential Revision: https://reviews.llvm.org/D149242
compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors.inc
compiler-rt/test/sanitizer_common/TestCases/Linux/netent.cpp
compiler-rt/test/sanitizer_common/TestCases/Linux/protoent.cpp