Quantcast
Channel: Common Language Runtime Internals and Architecture forum
Viewing all articles
Browse latest Browse all 1710

KB4537820 causes System.ComponentModel.Win32Exception in .Net framework System.Drawing.Icon for WinForms apps on Windows 7 SP1

$
0
0

I need to report what appears to be a serious bug in the KB4537820 windows 7 sp1 automatic update that was released 11th Feb 2020 (https://support.microsoft.com/en-au/help/4537820/windows-7-update-kb4537820).

It is causing .net based applications to fail to start or crash due during operation due to unexpected Win32 exceptions related to the internal System.Drawing.Icon library. This has already started rolling out automatically to Windows 7 point of sale touchscreens and is causing their .net application based systems to fail completely.

Uninstalling that specific windows update fixes the issue.

An example of the failure error if accessing the Icon class is

System.ComponentModel.Win32Exception (0x80004005): The operation completed successfully
   at System.Drawing.Icon.Initialize(Int32 width, Int32 height)
   at System.Drawing.Icon..ctor(String fileName, Int32 width, Int32 height)

Another example occuring during startup of a WinForms application

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.ComponentModel.Win32Exception: The parameter is incorrect
   at System.Drawing.Icon.Initialize(Int32 width, Int32 height)
   at System.Drawing.Icon..ctor(SerializationInfo info, StreamingContext context)
   --- End of inner exception stack trace ---
   at System.RuntimeMethodHandle.SerializationInvoke(IRuntimeMethodInfo method, Object target, SerializationInfo info, StreamingContext& context)
   at System.Runtime.Serialization.ObjectManager.CompleteISerializableObject(Object obj, SerializationInfo info, StreamingContext context)
   at System.Runtime.Serialization.ObjectManager.FixupSpecialObject(ObjectHolder holder)
   at System.Runtime.Serialization.ObjectManager.DoFixups()
   at System.Runtime.Serialization.Formatters.Binary.ObjectReader.Deserialize(HeaderHandler handler, __BinaryParser serParser, Boolean fCheck, Boolean isCrossAppDomain, IMethodCallMessage methodCallMessage)
   at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Deserialize(Stream serializationStream, HeaderHandler handler, Boolean fCheck, Boolean isCrossAppDomain, IMethodCallMessage methodCallMessage)
   at System.Resources.ResourceReader.DeserializeObject(Int32 typeIndex)
   at System.Resources.ResourceReader._LoadObjectV2(Int32 pos, ResourceTypeCode& typeCode)
   at System.Resources.ResourceReader.LoadObjectV2(Int32 pos, ResourceTypeCode& typeCode)
   at System.Resources.ResourceReader.LoadObject(Int32 pos, ResourceTypeCode& typeCode)
   at System.Resources.RuntimeResourceSet.GetObject(String key, Boolean ignoreCase, Boolean isString)
   at System.Resources.RuntimeResourceSet.GetObject(String key, Boolean ignoreCase)
   at System.Resources.ResourceManager.GetObject(String name, CultureInfo culture, Boolean wrapUnmanagedMemStream)
   at System.Resources.ResourceManager.GetObject(String name)
   at ClientApp_WinForms.MainForm.InitializeComponent()
   at ClientApp_WinForms.MainForm..ctor()
   at ClientApp_Win.Program.Main(String[] args)"

I can confirm so far I have seen this across a number of different .net apps, some using .net 4, others using .net 4.6.1





Viewing all articles
Browse latest Browse all 1710

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>