[PATCH] D26638: Don't pass nullptr into memcpy

Vitaly Buka via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 14 14:40:43 PST 2016


vitalybuka added a comment.

Majnemer, You are right
// here if Buffer is empty:
if (Offset > - Data.size())

  return make_error<MSFError>(msf_error_code::insufficient_buffer);

so it's essentially if (Offset >0 || Data.size() >0 )

I should submit the first patch which I've changed in the last moment for "early return" :-)


Repository:
  rL LLVM

https://reviews.llvm.org/D26638





More information about the llvm-commits mailing list