Fix rtc offset calculation for timezones that are not integral hours.

This commit is contained in:
blymn 2006-04-26 09:57:01 +00:00
parent 27048c613e
commit f79b447e34

View File

@ -1,6 +1,6 @@
#!/bin/sh
#
# $NetBSD: rtclocaltime,v 1.3 2004/08/13 18:08:03 mycroft Exp $
# $NetBSD: rtclocaltime,v 1.4 2006/04/26 09:57:01 blymn Exp $
#
# PROVIDE: rtclocaltime
@ -25,7 +25,7 @@ rtclocaltime_start()
sign = 1;
}
minutes = offset % 100;
hours = offset / 100;
hours = int(offset / 100);
offset = sign * (hours * 60 + minutes);
print offset;
}')