forked from OSchip/llvm-project
Fix crypt.cpp sanitizer test on FreeBSD
FreeBSD doesn't provide a crypt.h header but instead defines the functions in unistd.h. Use __has_include() to handle that case. Reviewed By: #sanitizers, vitalybuka Differential Revision: https://reviews.llvm.org/D85406
This commit is contained in:
parent
5695fa9190
commit
39d2506461
|
@ -6,7 +6,9 @@
|
|||
#include <assert.h>
|
||||
#include <unistd.h>
|
||||
#include <cstring>
|
||||
#if __has_include(<crypt.h>)
|
||||
#include <crypt.h>
|
||||
#endif
|
||||
|
||||
int
|
||||
main (int argc, char** argv)
|
||||
|
|
Loading…
Reference in New Issue