[PATCH] D15098: Libfuzzer: do not pass null into user function

Mike Aizatsky via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 1 12:28:06 PST 2015


aizatsky marked 2 inline comments as done.

================
Comment at: lib/Fuzzer/FuzzerLoop.cpp:242
@@ +241,3 @@
+  const uint8_t *Data = U.data();
+  static uint8_t EmptyData;
+  if (!Data) {
----------------
kcc wrote:
> Looks weird. 
> I would prefer to have assert(!U.empty()) and enforce it in callers. 
There are too many paths that lead here. Plus, didn't we agree that its ok to call it with empty unit?


http://reviews.llvm.org/D15098





More information about the llvm-commits mailing list