fix-numeric-type
authorDebian Multimedia Maintainers <debian-multimedia@lists.debian.org>
Sun, 3 Feb 2019 21:31:06 +0000 (21:31 +0000)
committerGeorges Khaznadar <georgesk@debian.org>
Sun, 3 Feb 2019 21:31:06 +0000 (21:31 +0000)
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);
     }