]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/contrib/strutl.cc
Lift the 1024-character limit on configuration file lines.
[apt.git] / apt-pkg / contrib / strutl.cc
index 37d263794b42b9c2049096068e2b3b99124371bd..a04c266ba1e9db9d378415e93d9472490c39bd26 100644 (file)
    ##################################################################### */
                                                                        /*}}}*/
 // Includes                                                            /*{{{*/
-#ifdef __GNUG__
-#pragma implementation "apt-pkg/strutl.h"
-#endif
-
 #include <apt-pkg/strutl.h>
 #include <apt-pkg/fileutl.h>
 #include <apt-pkg/error.h>
@@ -28,6 +24,7 @@
 #include <ctype.h>
 #include <string.h>
 #include <stdio.h>
+#include <algorithm>
 #include <unistd.h>
 #include <regex.h>
 #include <errno.h>
@@ -334,19 +331,19 @@ string TimeToStr(unsigned long Sec)
    {
       if (Sec > 60*60*24)
       {
-        sprintf(S,"%lid %lih%lim%lis",Sec/60/60/24,(Sec/60/60) % 24,(Sec/60) % 60,Sec % 60);
+        sprintf(S,"%lid %lih%limin%lis",Sec/60/60/24,(Sec/60/60) % 24,(Sec/60) % 60,Sec % 60);
         break;
       }
       
       if (Sec > 60*60)
       {
-        sprintf(S,"%lih%lim%lis",Sec/60/60,(Sec/60) % 60,Sec % 60);
+        sprintf(S,"%lih%limin%lis",Sec/60/60,(Sec/60) % 60,Sec % 60);
         break;
       }
       
       if (Sec > 60)
       {
-        sprintf(S,"%lim%lis",Sec/60,Sec % 60);
+        sprintf(S,"%limin%lis",Sec/60,Sec % 60);
         break;
       }