fix-numeric-type
authorDebian Multimedia Maintainers <debian-multimedia@lists.debian.org>
Sat, 29 Jun 2019 01:02:25 +0000 (02:02 +0100)
committerPeter Michael Green <plugwash@raspbian.org>
Sat, 29 Jun 2019 01:02:25 +0000 (02:02 +0100)
fixed a type inconsistency: forced the result of get_nanoseconds() to

fixed a type inconsistency: forced the result of get_nanoseconds() to
double before the division by 1000.

Gbp-Pq: Name fix-numeric-type.patch

server/supernova/utilities/time_tag.hpp

index 33b1effd80d4f597179d0c5eab26d70141e29564..bfedbf731f4de14d8608979f737da5a52b89703a 100644 (file)
@@ -229,7 +229,7 @@ public:
 #ifdef BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG
         time_duration offset = seconds(get_secs() - ntp_offset) + nanoseconds(get_nanoseconds());
 #else
-        time_duration offset = seconds(get_secs() - ntp_offset) + microseconds(get_nanoseconds()/1000);
+        time_duration offset = seconds(get_secs() - ntp_offset) + microseconds((long) get_nanoseconds()/1000);
 #endif
         return ptime(base, offset);
     }