Commit 9c4ce90b authored by Christopher Dykes's avatar Christopher Dykes Committed by Facebook Github Bot 3

Make static analysis happy about the length of patternBuf

Summary: The static analysis doesn't quite understand that we are assigning a NUL to, at most, `patternBuf[MAX_PATH + 1]` so increase the buffer size slightly to make it happy.

Reviewed By: yfeldblum

Differential Revision: D3571923

fbshipit-source-id: c027e2b253dc3e56d13e9a15a0e960a6aa3a0e6c
parent 9d4e8129
......@@ -34,7 +34,7 @@ struct DIR {
}
DIR* open() {
wchar_t patternBuf[MAX_PATH + 2];
wchar_t patternBuf[MAX_PATH + 3];
size_t len;
if (mbstowcs_s(&len, patternBuf, MAX_PATH, pattern.c_str(), MAX_PATH - 2)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment