]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/contrib/hashes.cc
* some WS fixes
[apt.git] / apt-pkg / contrib / hashes.cc
index af741b67278b671385070ea0e1f5d19253299028..b17b9431989e59ffcab886c40ceff0205594578b 100644 (file)
@@ -30,8 +30,8 @@ bool Hashes::AddFD(int Fd,unsigned long Size)
    int Res = 0;
    while (Size != 0)
    {
-      Res = read(Fd,Buf,MIN(Size,sizeof(Buf)));
-      if (Res < 0 || (unsigned)Res != MIN(Size,sizeof(Buf)))
+      Res = read(Fd,Buf,min(Size,(unsigned long)sizeof(Buf)));
+      if (Res < 0 || (unsigned)Res != min(Size,(unsigned long)sizeof(Buf)))
         return false;
       Size -= Res;
       MD5.Add(Buf,Res);