]> arthur.barton.de Git - bup.git/blobdiff - lib/bup/helpers.py
helpers.localtime: avoid floor-related deprecation warning
[bup.git] / lib / bup / helpers.py
index 788efb07a9c4ffb30a414a4cbf6dd211104748ae..2b0b6ed2c6ddeee83c686b422961beb68d375826 100644 (file)
@@ -1128,7 +1128,7 @@ if _localtime:
 # module, which doesn't appear willing to ignore the extra items.
 if _localtime:
     def localtime(time):
-        return bup_time(*_helpers.localtime(floor(time)))
+        return bup_time(*_helpers.localtime(int(floor(time))))
     def utc_offset_str(t):
         """Return the local offset from UTC as "+hhmm" or "-hhmm" for time t.
         If the current UTC offset does not represent an integer number