Search Issue Tracker

Fixed in 2019.3

Fixed in 2018.3, 2019.1

Votes

0

Found in

2018.1.9f1

2018.1.9f2

2018.4

2019.2.0a1

2019.3.0a1

Issue ID

1076679

Regression

Yes

When the registry value for "TimeZoneKeyName" is empty, null or invalid, "TimeZoneNotFoundException" exceptions are thrown

Windows

-

Reproduction steps:
1. Open "Regedit" -> "Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation"
2. Change "TimeZoneKeyName" value data to gibberish
3. Create a New or Open an existing Project
4. In the Editor log find error: "TimeZoneNotFoundException: Exception of type 'System.TimeZoneNotFoundException' was thrown."

Expected Result: Unity handles invalid "TimeZoneKeyName" registry values
Actual Result: "TimeZoneNotFoundException" errors are thrown when the "TimeZoneKeyName" registry value is invalid and the Editor/Build is unusable

Reproduced with: 2019.3.0b5, 2019.3.0b1, 2019.3.0a1, 2019.2.9f1, 2019.2.0a4, 2019.2.0a1, 2019.1.14f1, 2018.4.11f1, 2018.3.14f1, 2018.1.9f2
Did not reproduce on: 2020.1.0a8, 2019.3.0b6, 2017.4.33f1

Comments (3)

  1. C87dbe6cd082d9a8f85e848c8d5ec4c0?d=mm

    Ladace

    Oct 10, 2019 19:09

    This bug still occur in 2018.4.10f1

    System.TimeZoneInfo.FindSystemTimeZoneById (System.String id) (at <7ba07f088431485bb722f3b3373e87ee>:0)
    System.TimeZoneInfo.CreateLocal () (at <7ba07f088431485bb722f3b3373e87ee>:0)
    System.TimeZoneInfo.get_Local () (at <7ba07f088431485bb722f3b3373e87ee>:0)
    System.TimeZoneInfo.GetDateTimeNowUtcOffsetFromUtc (System.DateTime time, System.Boolean& isAmbiguousLocalDst) (at <7ba07f088431485bb722f3b3373e87ee>:0)
    System.DateTime.get_Now () (at <7ba07f088431485bb722f3b3373e87ee>:0)
    UnityEngine.GUI..cctor () (at <512b71eca5984710bf8fd1111d3654a2>:0)
    Rethrow as TypeInitializationException: The type initializer for 'UnityEngine.GUI' threw an exception.
    Game.OnGUI () (at <1de034b8c89e49d18ee0edb1d1b76fa7>:0)

  2. 4da2d989f07301d4aa83288831ae4b2c?d=mm

    SimDevs

    Sep 18, 2019 10:21

    Still happens on 2018.4.8f1

    System.TimeZoneInfo.FindSystemTimeZoneById (System.String id) (at <00000000000000000000000000000000>:0)
    System.TimeZoneInfo.CreateLocal () (at <00000000000000000000000000000000>:0)
    System.TimeZoneInfo.get_Local () (at <00000000000000000000000000000000>:0)
    System.TimeZoneInfo.GetDateTimeNowUtcOffsetFromUtc (System.DateTime time, System.Boolean& isAmbiguousLocalDst) (at <00000000000000000000000000000000>:0)
    System.DateTime.get_Now () (at <00000000000000000000000000000000>:0)

  3. Ac3d8d34ad9e40ea2fc859b9ccc8f82d?d=mm

    chaixl

    Jun 25, 2019 01:51

    This bug still occur in 2018.4.2f1.

    System.TimeZoneInfo.FindSystemTimeZoneById (System.String id) (at <d7ac571ca2d04b2f981d0d886fa067cf>:0)
    System.TimeZoneInfo.CreateLocal () (at <d7ac571ca2d04b2f981d0d886fa067cf>:0)
    System.TimeZoneInfo.get_Local () (at <d7ac571ca2d04b2f981d0d886fa067cf>:0)
    System.TimeZoneInfo.GetDateTimeNowUtcOffsetFromUtc (System.DateTime time, System.Boolean& isAmbiguousLocalDst) (at <d7ac571ca2d04b2f981d0d886fa067cf>:0)
    System.DateTime.get_Now () (at <d7ac571ca2d04b2f981d0d886fa067cf>:0)
    UnityEngine.GUI..cctor () (at <a0287f84f481422a879965ed0aa2afc0>:0)
    Rethrow as TypeInitializationException: The type initializer for 'UnityEngine.GUI' threw an exception.
    UnityEngine.GUIUtility.ResetGlobalState () (at <a0287f84f481422a879965ed0aa2afc0>:0)
    UnityEngine.GUIUtility.BeginGUI (System.Int32 skinMode, System.Int32 instanceID, System.Int32 useGUILayout) (at <a0287f84f481422a879965ed0aa2afc0>:0)

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.