]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
utime: use to_timespec for conversion 825/head
authorNoah Watkins <noahwatkins@gmail.com>
Sun, 21 Jul 2013 01:41:39 +0000 (18:41 -0700)
committerNoah Watkins <noahwatkins@gmail.com>
Tue, 5 Nov 2013 19:49:35 +0000 (11:49 -0800)
Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
src/include/utime.h

index e13460593062b8d1a756712139968bbcf061bfb0..5bebc70a3422c671e71dc97454196ea8cd5be638 100644 (file)
@@ -138,8 +138,9 @@ public:
   }
 
   void sleep() {
-    struct timespec ts = { (__time_t)tv.tv_sec, (long)tv.tv_nsec };
-    nanosleep(&ts, &ts);
+    struct timespec ts;
+    to_timespec(&ts);
+    nanosleep(&ts, NULL);
   }
 
   // output