[PATCH] libcxx random_device for Win32

Yaron Keren yaron.keren at gmail.com
Tue Oct 8 04:31:12 PDT 2013


Hi,

I fixed the issues.
__f_ data member will be used if !_WIN32 as a file descriptor so it's
#ifdef-d.

Yaron



2013/10/8 Nico Rieck <nico.rieck at gmail.com>

>  #  endif
> +#  // Must be defined before stdlib.h is included to enable rand_s().
> +#  define _CRT_RAND_S
>  #endif  // _WIN32
>
> Since rand_s is never used in a libc++ header, I don't think it should be
> defined here.
>
> There are also trailing whitespace in the patch. The __f_ data member is
> unused and should be removed. (It also can't hold any HANDLE if that's the
> reason you kept it around.) And I see no need to duplicate entropy().
>
> -Nico
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20131008/ec7fed4b/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: libcxx-rands.diff
Type: application/octet-stream
Size: 1370 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20131008/ec7fed4b/attachment.obj>


More information about the cfe-commits mailing list