[PATCH] D17479: [sanitizer] Move recvmsg and recv interceptors to sanitizer_common.
Dmitry Vyukov via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 24 10:12:55 PST 2016
dvyukov added a comment.
Otherwise looks good.
================
Comment at: lib/sanitizer_common/sanitizer_common_interceptors.inc:5364
@@ +5363,3 @@
+ COMMON_INTERCEPTOR_WRITE_RANGE(ctx, buf, len);
+ COMMON_INTERCEPTOR_UNPOISON_SRCADDR(srcaddr, addrlen, srcaddr_sz);
+ }
----------------
I would just do:
if (srcaddr)
__msan_unpoison(srcaddr, Min(srcaddr_sz, *addrlen));
The macro makes code more convoluted without adding significant value. Every time I read this function I will need to go and check macro definition.
Repository:
rL LLVM
http://reviews.llvm.org/D17479
More information about the llvm-commits
mailing list