]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/boost/tools/build/src/engine/timestamp.cpp
update source to Ceph Pacific 16.2.2
[ceph.git] / ceph / src / boost / tools / build / src / engine / timestamp.cpp
index 2add949f97dbd59e67b11dd44cce1d85eb659cba..67090ca55402ddd4ac34aa4ede064c4274d10a2b 100644 (file)
@@ -19,8 +19,6 @@
  *  timestamp_done()      - free timestamp tables
  *
  * Internal routines:
- *  time_enter()      - internal worker callback for scanning archives &
- *                      directories
  *  free_timestamps() - worker function for freeing timestamp table contents
  */
 
@@ -31,7 +29,7 @@
 #include "hash.h"
 #include "object.h"
 #include "pathsys.h"
-#include "strings.h"
+#include "jam_strings.h"
 #include "output.h"
 
 
@@ -60,18 +58,6 @@ typedef struct _binding
 
 static struct hash * bindhash = 0;
 
-static void time_enter( void *, OBJECT *, int const found,
-    timestamp const * const );
-
-static const char * time_progress[] =
-{
-    "INIT",
-    "NOENTRY",
-    "SPOTTED",
-    "MISSING",
-    "FOUND"
-};
-
 
 #ifdef OS_NT
 /*
@@ -110,9 +96,10 @@ void timestamp_clear( timestamp * const time )
 
 int timestamp_cmp( timestamp const * const lhs, timestamp const * const rhs )
 {
-    return lhs->secs == rhs->secs
+    return int(
+        lhs->secs == rhs->secs
         ? lhs->nsecs - rhs->nsecs
-        : lhs->secs - rhs->secs;
+        : lhs->secs - rhs->secs );
 }
 
 
@@ -162,13 +149,6 @@ void timestamp_from_path( timestamp * const time, OBJECT * const path )
 {
     PROFILE_ENTER( timestamp );
 
-    PATHNAME f1;
-    PATHNAME f2;
-    int found;
-    BINDING * b;
-    string buf[ 1 ];
-
-
     if ( file_time( path, time ) < 0 )
         timestamp_clear( time );
 
@@ -218,37 +198,6 @@ char const * timestamp_timestr( timestamp const * const time )
 }
 
 
-/*
- * time_enter() - internal worker callback for scanning archives & directories
- */
-
-static void time_enter( void * closure, OBJECT * target, int const found,
-    timestamp const * const time )
-{
-    int item_found;
-    BINDING * b;
-    struct hash * const bindhash = (struct hash *)closure;
-
-    target = path_as_key( target );
-
-    b = (BINDING *)hash_insert( bindhash, target, &item_found );
-    if ( !item_found )
-    {
-        b->name = object_copy( target );
-        b->flags = 0;
-    }
-
-    timestamp_copy( &b->time, time );
-    b->progress = found ? BIND_FOUND : BIND_SPOTTED;
-
-    if ( DEBUG_BINDSCAN )
-        out_printf( "time ( %s ) : %s\n", object_str( target ), time_progress[
-            b->progress ] );
-
-    object_free( target );
-}
-
-
 /*
  * free_timestamps() - worker function for freeing timestamp table contents
  */