Explicit conversions to int from size_t for MSVC (64-bit) in apps

This commit is contained in:
Paul Bakker 2013-11-30 15:14:38 +01:00
parent 256a4afb57
commit 0748895b68
3 changed files with 3 additions and 3 deletions

View file

@ -219,7 +219,7 @@ int main( int argc, char *argv[] )
fflush( stdout );
n = dhm.len;
if( ( ret = dhm_make_public( &dhm, dhm.len, buf, n,
if( ( ret = dhm_make_public( &dhm, (int) dhm.len, buf, n,
ctr_drbg_random, &ctr_drbg ) ) != 0 )
{
printf( " failed\n ! dhm_make_public returned %d\n\n", ret );

View file

@ -182,7 +182,7 @@ int main( int argc, char *argv[] )
memset( buf, 0, sizeof( buf ) );
if( ( ret = dhm_make_params( &dhm, mpi_size( &dhm.P ), buf, &n,
if( ( ret = dhm_make_params( &dhm, (int) mpi_size( &dhm.P ), buf, &n,
ctr_drbg_random, &ctr_drbg ) ) != 0 )
{
printf( " failed\n ! dhm_make_params returned %d\n\n", ret );

View file

@ -170,7 +170,7 @@ int main( int argc, char *argv[] )
fgets( buf, 1024, f );
fclose( f );
i = strlen( buf );
i = (int) strlen( buf );
if( buf[i - 1] == '\n' ) buf[i - 1] = '\0';
if( buf[i - 2] == '\r' ) buf[i - 2] = '\0';
opt.password = buf;