https://bugs.winehq.org/show_bug.cgi?id=37760
Bug ID: 37760 Summary: Several .Net applications fail under wine-mono with System.TimeZoneNotFoundException Product: Wine Version: 1.7.33 Hardware: x86 URL: http://dlm.cypress.com.edgesuite.net/akdlm/downloadman ager/software/PSoCDesignerSetup.exe OS: Linux Status: NEW Keywords: download Severity: normal Priority: P2 Component: mscoree Assignee: wine-bugs@winehq.org Reporter: austinenglish@gmail.com Distribution: ---
I noticed this in http://dlm.cypress.com.edgesuite.net/akdlm/downloadmanager/software/PSoCDesi... while looking at bug 31369, but it's also been reported in bug 28177 (and I recall seeing it in some other applications, but I don't have a note of which ones they were).
Native .Net via winetricks works around it. (dotnet20sp2 in the case of PSoC Designer)
Unhandled Exception: System.TimeZoneNotFoundException: Exception of type 'System.TimeZoneNotFoundException' was thrown. at System.TimeZoneInfo.get_Local () [0x00000] in <filename unknown>:0 at System.CurrentSystemTimeZone.GetUtcOffset (DateTime time) [0x00000] in <filename unknown>:0 at System.TimeZone.GetLocalTimeDiff (DateTime time) [0x00000] in <filename unknown>:0 at System.DateTime.get_Now () [0x00000] in <filename unknown>:0 at System.Windows.Forms.TextBoxBase..ctor () [0x00000] in <filename unknown>:0 at System.Windows.Forms.RichTextBox..ctor () [0x00000] in <filename unknown>:0 at (wrapper remoting-invoke-with-check) System.Windows.Forms.RichTextBox:.ctor () at Cypress.CyInstaller.Gui.CyInstallerWizard.InitializeComponent () [0x00000] in <filename unknown>:0 at Cypress.CyInstaller.Gui.CyInstallerWizard..ctor (Cypress.CyInstaller.Core.CyInstallerCore core) [0x00000] in <filename unknown>:0 at (wrapper remoting-invoke-with-check) Cypress.CyInstaller.Gui.CyInstallerWizard:.ctor (Cypress.CyInstaller.Core.CyInstallerCore) at psocdesignerinstaller.Program.Main (System.String[] commandLine) [0x00000] in <filename unknown>:0 [ERROR] FATAL UNHANDLED EXCEPTION: System.TimeZoneNotFoundException: Exception of type 'System.TimeZoneNotFoundException' was thrown. at System.TimeZoneInfo.get_Local () [0x00000] in <filename unknown>:0 at System.CurrentSystemTimeZone.GetUtcOffset (DateTime time) [0x00000] in <filename unknown>:0 at System.TimeZone.GetLocalTimeDiff (DateTime time) [0x00000] in <filename unknown>:0 at System.DateTime.get_Now () [0x00000] in <filename unknown>:0 at System.Windows.Forms.TextBoxBase..ctor () [0x00000] in <filename unknown>:0 at System.Windows.Forms.RichTextBox..ctor () [0x00000] in <filename unknown>:0 at (wrapper remoting-invoke-with-check) System.Windows.Forms.RichTextBox:.ctor () at Cypress.CyInstaller.Gui.CyInstallerWizard.InitializeComponent () [0x00000] in <filename unknown>:0 at Cypress.CyInstaller.Gui.CyInstallerWizard..ctor (Cypress.CyInstaller.Core.CyInstallerCore core) [0x00000] in <filename unknown>:0 at (wrapper remoting-invoke-with-check) Cypress.CyInstaller.Gui.CyInstallerWizard:.ctor (Cypress.CyInstaller.Core.CyInstallerCore) at psocdesignerinstaller.Program.Main (System.String[] commandLine) [0x00000] in <filename unknown>:0
https://bugs.winehq.org/show_bug.cgi?id=37760
Don Pobanz dpobanz@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |dpobanz@gmail.com
https://bugs.winehq.org/show_bug.cgi?id=37760
Alistair Leslie-Hughes leslie_alistair@hotmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |leslie_alistair@hotmail.com
--- Comment #1 from Alistair Leslie-Hughes leslie_alistair@hotmail.com --- An upstream patch b3eccc8a798847a6f405b65048acfb7ca74944d0 should correct this.
https://bugs.winehq.org/show_bug.cgi?id=37760
Alistair Leslie-Hughes leslie_alistair@hotmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |madewokherd@gmail.com
https://bugs.winehq.org/show_bug.cgi?id=37760
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |n296869@rtrtr.com
--- Comment #2 from Anastasius Focht focht@gmx.net --- *** Bug 38024 has been marked as a duplicate of this bug. ***
https://bugs.winehq.org/show_bug.cgi?id=37760
Ronny Schmatzler schmatzler@googlemail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |schmatzler@googlemail.com
--- Comment #3 from Ronny Schmatzler schmatzler@googlemail.com --- Bug still happens on Wine 1.7.37 with Cry of Fear.
https://bugs.winehq.org/show_bug.cgi?id=37760
--- Comment #4 from Vincent Povirk madewokherd@gmail.com --- I tried this with the upstream patch applied, and I'm getting a new exception in the same call:
System.InvalidTimeZoneException: Exception of type 'System.InvalidTimeZoneException' was thrown. at System.TimeZoneInfo.FromRegistryKey (System.String id, Microsoft.Win32.RegistryKey key) [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.FindSystemTimeZoneById (System.String id) [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.CreateLocal () [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.get_Local () [0x00000] in <filename unknown>:0 at System.CurrentSystemTimeZone.GetUtcOffset (DateTime time) [0x00000] in <filename unknown>:0 at System.TimeZone.GetLocalTimeDiff (DateTime time) [0x00000] in <filename unknown>:0 at System.DateTime.get_Now () [0x00000] in <filename unknown>:0
https://bugs.winehq.org/show_bug.cgi?id=37760
--- Comment #5 from Vincent Povirk madewokherd@gmail.com --- Apparently, Mono is trying to use the "LocalZoneKeyName" value in HKLM\SYSTEM\CurrentControlSet\Control\TimeZoneInformation to find the current timezone, and on Wine this is an empty string value.
https://bugs.winehq.org/show_bug.cgi?id=37760
--- Comment #6 from Vincent Povirk madewokherd@gmail.com --- I don't think System.TimeZoneInfo.get_Local has ever worked in Wine, but it wasn't previously required by System.DateTime.get_Now.
https://bugs.winehq.org/show_bug.cgi?id=37760
Vincent Povirk madewokherd@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Severity|normal |major
https://bugs.winehq.org/show_bug.cgi?id=37760
--- Comment #7 from Vincent Povirk madewokherd@gmail.com --- Whoops, the value name is "TimeZoneKeyName", not "LocalZoneKeyName".
https://bugs.winehq.org/show_bug.cgi?id=37760
--- Comment #8 from Alistair Leslie-Hughes leslie_alistair@hotmail.com --- That is correct. Once TimeZoneKeyName is set to the valid value the exception will go away.
I looked into setting this registry entry when .wine was updated or created, but didnt discovered a good place to set it.
https://bugs.winehq.org/show_bug.cgi?id=37760
--- Comment #9 from Vincent Povirk madewokherd@gmail.com --- While it'd be nice for Wine to set the registry value, it seems complicated as we should probably do it once on prefix initialization using logic currently in ntdll. So I made a temporary hack in Mono: https://github.com/madewokherd/mono/commit/8a91a102e477b1c136d9b83b43437a7a7...
But now my week is over. Hopefully I can get a release out with this fixed next week.
https://bugs.winehq.org/show_bug.cgi?id=37760
--- Comment #10 from Vincent Povirk madewokherd@gmail.com --- My best guess for fixing Wine long-term was that the timezone detection logic should be moved into wineboot, and ntdll should use the registry for its timezone information.
https://bugs.winehq.org/show_bug.cgi?id=37760
Qian Hong fracting@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |fracting@gmail.com
https://bugs.winehq.org/show_bug.cgi?id=37760
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |grendal74.geo@yahoo.com
--- Comment #11 from Anastasius Focht focht@gmx.net --- *** Bug 38507 has been marked as a duplicate of this bug. ***
https://bugs.winehq.org/show_bug.cgi?id=37760
Sergey Isakov isakov-sl@bk.ru changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |isakov-sl@bk.ru
--- Comment #12 from Sergey Isakov isakov-sl@bk.ru --- This bug is already resolved?
https://bugs.winehq.org/show_bug.cgi?id=37760
--- Comment #13 from Andrey Gusev andrey.goosev@gmail.com --- Still in wine-3.2-45-g538263d0ef
Unhandled Exception: System.TypeInitializationException: An exception was thrown by the type initializer for Utils ---> System.InvalidTimeZoneException: Exception of type 'System.InvalidTimeZoneException' was thrown. at System.TimeZoneInfo.FromRegistryKey (System.String id, Microsoft.Win32.RegistryKey key) [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.FindSystemTimeZoneById (System.String id) [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.CreateLocal () [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.get_Local () [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.GetDateTimeNowUtcOffsetFromUtc (DateTime time, System.Boolean& isAmbiguousLocalDst) [0x00000] in <filename unknown>:0 at System.DateTime.get_Now () [0x00000] in <filename unknown>:0 at Utils..cctor () [0x00000] in <filename unknown>:0 --- End of inner exception stack trace --- at dedicated.server.MainClass.Main (System.String[] args) [0x00000] in <filename unknown>:0 [ERROR] FATAL UNHANDLED EXCEPTION: System.TypeInitializationException: An exception was thrown by the type initializer for Utils ---> System.InvalidTimeZoneException: Exception of type 'System.InvalidTimeZoneException' was thrown. at System.TimeZoneInfo.FromRegistryKey (System.String id, Microsoft.Win32.RegistryKey key) [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.FindSystemTimeZoneById (System.String id) [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.CreateLocal () [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.get_Local () [0x00000] in <filename unknown>:0 at System.TimeZoneInfo.GetDateTimeNowUtcOffsetFromUtc (DateTime time, System.Boolean& isAmbiguousLocalDst) [0x00000] in <filename unknown>:0 at System.DateTime.get_Now () [0x00000] in <filename unknown>:0 at Utils..cctor () [0x00000] in <filename unknown>:0 --- End of inner exception stack trace --- at dedicated.server.MainClass.Main (System.String[] args) [0x00000] in <filename unknown>:0
https://bugs.winehq.org/show_bug.cgi?id=37760
Ken Sharp imwellcushtymelike@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |sagawa.aki+winebugs@gmail.c | |om
--- Comment #14 from Ken Sharp imwellcushtymelike@gmail.com --- *** Bug 42719 has been marked as a duplicate of this bug. ***
https://bugs.winehq.org/show_bug.cgi?id=37760
Ken Sharp imwellcushtymelike@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.winehq.org/sho | |w_bug.cgi?id=38431
https://bugs.winehq.org/show_bug.cgi?id=37760
Alistair Leslie-Hughes leslie_alistair@hotmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |4c2cc57c7f43237afd58bd747e0 | |b2ec13a386702 Resolution|--- |FIXED Status|NEW |RESOLVED
--- Comment #15 from Alistair Leslie-Hughes leslie_alistair@hotmail.com --- Fixed by https://source.winehq.org/git/wine.git/?a=commit;h=4c2cc57c7f43237afd58bd747...
https://bugs.winehq.org/show_bug.cgi?id=37760
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #16 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 3.7.