serialize.h: CAutoFile's read and write may take size_t nSize
authorJeff Garzik <jeff@garzik.org>
Sun, 15 Apr 2012 20:59:09 +0000 (16:59 -0400)
committerJeff Garzik <jgarzik@redhat.com>
Sun, 15 Apr 2012 20:59:09 +0000 (16:59 -0400)
src/serialize.h

index 2d4aaba..5fb3aa6 100644 (file)
@@ -1190,7 +1190,7 @@ public:
     void ReadVersion()           { *this >> nVersion; }
     void WriteVersion()          { *this << nVersion; }
 
-    CAutoFile& read(char* pch, int nSize)
+    CAutoFile& read(char* pch, size_t nSize)
     {
         if (!file)
             throw std::ios_base::failure("CAutoFile::read : file handle is NULL");
@@ -1199,7 +1199,7 @@ public:
         return (*this);
     }
 
-    CAutoFile& write(const char* pch, int nSize)
+    CAutoFile& write(const char* pch, size_t nSize)
     {
         if (!file)
             throw std::ios_base::failure("CAutoFile::write : file handle is NULL");