diff options
author | Aaron Ballman <aaron@aaronballman.com> | 2014-02-04 14:49:21 +0000 |
---|---|---|
committer | Aaron Ballman <aaron@aaronballman.com> | 2014-02-04 14:49:21 +0000 |
commit | 78440734029c40841904a05663c2c38e7b258214 (patch) | |
tree | d1109c52253e39116dff054cc278fc6daf85cf3c /llvm/lib/Support/Process.cpp | |
parent | 2da2cee706b0d02e8dc57ef662b1fe11f4617c43 (diff) | |
download | bcm5719-llvm-78440734029c40841904a05663c2c38e7b258214.tar.gz bcm5719-llvm-78440734029c40841904a05663c2c38e7b258214.zip |
Implemented support for Process::GetRandomNumber on Windows.
Patch thanks to Stephan Tolksdorf!
llvm-svn: 200767
Diffstat (limited to 'llvm/lib/Support/Process.cpp')
-rw-r--r-- | llvm/lib/Support/Process.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Support/Process.cpp b/llvm/lib/Support/Process.cpp index d5168f03a6d..1360842753d 100644 --- a/llvm/lib/Support/Process.cpp +++ b/llvm/lib/Support/Process.cpp @@ -12,6 +12,11 @@ //===----------------------------------------------------------------------===// #include "llvm/Config/config.h" +#if LLVM_ON_WIN32 + // This define makes stdlib.h declare the rand_s function. +#define _CRT_RAND_S +#include <stdlib.h> +#endif #include "llvm/Support/ErrorHandling.h" #include "llvm/Support/Process.h" |