commit 429cac991d10fb0d9242232bda8282f220ea1d73
parent 45493dc71e091016f874638e733d0ac1369faa3e
Author: oblique <psyberbits@gmail.com>
Date: Sun, 14 Apr 2013 04:26:56 +0300
subsync.go: minor change in msecs_to_time function
Diffstat:
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/subsync.go b/subsync.go
@@ -64,12 +64,11 @@ func msecs_to_time(msecs uint) string {
var h, m, s, ms uint
h = msecs / (60 * 60 * 1000)
- msecs = msecs % (60 * 60 * 1000)
+ msecs %= 60 * 60 * 1000
m = msecs / (60 * 1000)
- msecs = msecs % (60 * 1000)
+ msecs %= 60 * 1000
s = msecs / 1000
- msecs = msecs % 1000
- ms = msecs
+ ms = msecs % 1000
tm := fmt.Sprintf("%02d:%02d:%02d,%03d", h, m, s, ms)