aboutsummaryrefslogtreecommitdiff
path: root/hw/pc.c
diff options
context:
space:
mode:
authorbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2004-06-03 12:49:50 +0000
committerbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2004-06-03 12:49:50 +0000
commitee22c2f7dbcc59d9b0c0c9e08fafc9c4759b37fc (patch)
tree18b2141958e7f3a974b645da8d62276e434f8bcc /hw/pc.c
parentbe3edd95908863ae39936d1b0608f0727256a3c3 (diff)
downloadqemu-ee22c2f7dbcc59d9b0c0c9e08fafc9c4759b37fc.zip
qemu-ee22c2f7dbcc59d9b0c0c9e08fafc9c4759b37fc.tar.gz
qemu-ee22c2f7dbcc59d9b0c0c9e08fafc9c4759b37fc.tar.bz2
-localtime option
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@871 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'hw/pc.c')
-rw-r--r--hw/pc.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/hw/pc.c b/hw/pc.c
index 815d47f..eef120e 100644
--- a/hw/pc.c
+++ b/hw/pc.c
@@ -110,7 +110,10 @@ static void cmos_init(int ram_size, int boot_device)
/* set the CMOS date */
time(&ti);
- tm = gmtime(&ti);
+ if (rtc_utc)
+ tm = gmtime(&ti);
+ else
+ tm = localtime(&ti);
rtc_set_date(s, tm);
val = to_bcd(s, (tm->tm_year / 100) + 19);