Fix variable types

This commit is contained in:
Dmitry Marakasov 2015-09-17 15:20:38 +03:00
parent 29f9f28128
commit 9ecd4a12fe
3 changed files with 3 additions and 3 deletions

View File

@ -128,7 +128,7 @@ public:
if (position_ + size > container_.size())
return 0;
int toread = std::min((container_.size() - position_), maxnum * size);
size_t toread = std::min((container_.size() - position_), maxnum * size);
std::copy(container_.begin() + position_, container_.begin() + position_ + toread, reinterpret_cast<unsigned char*>(ptr));

View File

@ -90,7 +90,7 @@ private:
char* pos = static_cast<char*>(ptr);
pos += nread;
int count = nread % size;
size_t count = nread % size;
// put partially read object back into the stream
while (--count >= 0)

View File

@ -46,7 +46,7 @@ int main() try {
while (stream_pos < stream_end) {
Uint8* wav_end = wav.GetBuffer() + wav.GetLength();
int copylen = std::min(wav_end - wav_pos, stream_end - stream_pos);
size_t copylen = std::min(wav_end - wav_pos, stream_end - stream_pos);
std::copy(wav_pos, wav_pos + copylen, stream_pos);
stream_pos += copylen;