[PATCH] D40766: Handle NetBSD symbol renaming in msan_interceptors.cc

Vitaly Buka via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 6 11:47:13 PST 2017


vitalybuka added inline comments.


================
Comment at: lib/msan/msan_interceptors.cc:38
+#if SANITIZER_NETBSD
+#define gettimeofday __gettimeofday50
+#define getrusage __getrusage50
----------------
krytarowski wrote:
> vitalybuka wrote:
> > I expected you remove these too. However looks like we do the same in sanitizer_common_interceptors.inc
> > 
> >  __shmctl50  already defined there. Could you just delete  "#define shmctl __shmctl50" and "DECLARE_REAL(int, shmctl, int shmid, int cmd, void *buf)"
> > and move "INTERCEPTOR(void *, shmat" to just before "INTERCEPTOR(int, dl_iterate_phdr", after sanitizer_common_interceptors.inc ?
> > 
> > 
> It's not clear to me. `shmctl` is used in the `shmat` interceptor.
Correct. You just need to move shmat interceptor after "#include sanitizer_common_interceptors.inc"
sanitizer_common_interceptors.inc already declares READ(shmctl)


Repository:
  rL LLVM

https://reviews.llvm.org/D40766





More information about the llvm-commits mailing list