Merge remote-tracking branch 'origin/development' into development_new
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com> Conflicts: include/mbedtls/check_config.h: nearby edits library/entropy.c: nearby edits programs/random/gen_random_havege.c: modification vs. removal programs/ssl/ssl_test_lib.h: nearby edits programs/test/cpp_dummy_build.cpp: nearby edits visualc/VS2010/mbedTLS.vcxproj: automatically generated file, regenerated with scripts/generate_visualc_files.pl
This commit is contained in:
commit
73e3e2cb1a
217 changed files with 23474 additions and 8202 deletions
|
@ -106,6 +106,21 @@ static int getrandom_wrapper( void *buf, size_t buflen, unsigned int flags )
|
|||
#endif /* SYS_getrandom */
|
||||
#endif /* __linux__ || __midipix__ */
|
||||
|
||||
#if defined(__FreeBSD__) || defined(__DragonFly__)
|
||||
#include <sys/param.h>
|
||||
#if (defined(__FreeBSD__) && __FreeBSD_version >= 1200000) || \
|
||||
(defined(__DragonFly__) && __DragonFly_version >= 500700)
|
||||
#include <errno.h>
|
||||
#include <sys/random.h>
|
||||
#define HAVE_GETRANDOM
|
||||
static int getrandom_wrapper( void *buf, size_t buflen, unsigned int flags )
|
||||
{
|
||||
return getrandom( buf, buflen, flags );
|
||||
}
|
||||
#endif /* (__FreeBSD__ && __FreeBSD_version >= 1200000) ||
|
||||
(__DragonFly__ && __DragonFly_version >= 500700) */
|
||||
#endif /* __FreeBSD__ || __DragonFly__ */
|
||||
|
||||
/*
|
||||
* Some BSD systems provide KERN_ARND.
|
||||
* This is equivalent to reading from /dev/urandom, only it doesn't require an
|
||||
|
@ -202,13 +217,13 @@ int mbedtls_null_entropy_poll( void *data,
|
|||
{
|
||||
((void) data);
|
||||
((void) output);
|
||||
*olen = 0;
|
||||
|
||||
*olen = 0;
|
||||
if( len < sizeof(unsigned char) )
|
||||
return( 0 );
|
||||
|
||||
output[0] = 0;
|
||||
*olen = sizeof(unsigned char);
|
||||
|
||||
return( 0 );
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue