4,511,024 th visitor since 2017.2.1 ( Today : 1591 )
Programming
No. 491
Name. swindler
Subject. Vista의 Timezone 버그?
Main Cate. Java
Sub Cate.
Date. 2008-11-03 11:37
Hit. 3501 (210.182.190.136)
File.
현재 시간을 조회하면 Vista에서는 세팅과 상관없이
비정상적으로 출력이 된다.


System Property8의 user.timezone이 GMT로 나타난다. (OS세팅과 상관없이 무조건..)

System.setProperty("user.timezone", "Asia/Seoul"); 을 실행하고
나면 제대로 나타나긴 한다.


java 실행시에
-Duser.timezone=Asia/Seoul 을 넣어서 실행해도 된다.
System.propery를 세팅하는건 아무래도 OS dependent 한 code가 추가되므로
실행시 옵션을 주는게 바람직하지 않나 싶다.

[바로가기 링크] : http://coolx.net/cboard/develop/491



Name
Password
Comment
Copyright © 1999-2017, swindler. All rights reserved. 367,611 visitor ( 1999.1.8-2004.5.26 ), 2,405,771 ( -2017.01.31)

  2HLAB   2HLAB_Blog   RedToolBox   Omil   Omil_Blog