fix some of the many warnings

This commit is contained in:
Steve Checkoway
2004-05-16 08:23:14 +00:00
parent 43ef336eea
commit 77469f1951
3 changed files with 5 additions and 3 deletions
+1 -1
View File
@@ -112,7 +112,7 @@ unsigned int FileStore::CopyRangeTo2(BufferedTransformation &target, unsigned lo
return 0; // don't try to seek beyond the end of file
}
m_stream->seekg(newPosition);
unsigned long total = 0;
try
{
assert(!m_waiting);
+1 -1
View File
@@ -87,7 +87,7 @@ void NonblockingRng::GenerateBlock(byte *output, unsigned int size)
if (!CryptGenRandom(m_Provider.GetProviderHandle(), size, output))
throw OS_RNG_Err("CryptGenRandom");
#else
if (read(m_fd, output, size) != size)
if (read(m_fd, output, size) != int(size))
throw OS_RNG_Err("read /dev/urandom");
#endif
}
+3 -1
View File
@@ -9,7 +9,8 @@
#include "sha.h"
#include "algparam.h"
#include "oaep.cpp"
//This isn't in the repository and doesn't seem to be used
//#include "oaep.cpp"
NAMESPACE_BEGIN(CryptoPP)
@@ -73,6 +74,7 @@ class RSAPrimeSelector : public PrimeSelector
{
public:
RSAPrimeSelector(const Integer &e) : m_e(e) {}
virtual ~RSAPrimeSelector() { }
bool IsAcceptable(const Integer &candidate) const {return RelativelyPrime(m_e, candidate-Integer::One());}
Integer m_e;
};