]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/contrib/sha1.cc
* merged from apt--mvo
[apt.git] / apt-pkg / contrib / sha1.cc
index 9b402c5235824d5f83f3362069ab0a053080e3fa..b70f31dc6792619dea08ca492ecac8f6afc88b1a 100644 (file)
  */
                                                                        /*}}} */
 // Include Files                                                        /*{{{*/
  */
                                                                        /*}}} */
 // Include Files                                                        /*{{{*/
-#ifdef __GNUG__
-#pragma implementation "apt-pkg/sha1.h"
-#endif
-
 #include <apt-pkg/sha1.h>
 #include <apt-pkg/strutl.h>
 
 #include <apt-pkg/sha1.h>
 #include <apt-pkg/strutl.h>
 
@@ -347,7 +343,7 @@ bool SHA1Summation::AddFD(int Fd,unsigned long Size)
    while (Size != 0 || ToEOF)
    {
       unsigned n = sizeof(Buf);
    while (Size != 0 || ToEOF)
    {
       unsigned n = sizeof(Buf);
-      if (!ToEOF) n = MIN(Size,n);
+      if (!ToEOF) n = min(Size,(unsigned long)n);
       Res = read(Fd,Buf,n);
       if (Res < 0 || (!ToEOF && (unsigned) Res != n)) // error, or short read
         return false;
       Res = read(Fd,Buf,n);
       if (Res < 0 || (!ToEOF && (unsigned) Res != n)) // error, or short read
         return false;