diff --git a/ICSharpCode.Decompiler/TypeSystem/Implementation/CustomAttribute.cs b/ICSharpCode.Decompiler/TypeSystem/Implementation/CustomAttribute.cs index 3d58038b5..feb191d21 100644 --- a/ICSharpCode.Decompiler/TypeSystem/Implementation/CustomAttribute.cs +++ b/ICSharpCode.Decompiler/TypeSystem/Implementation/CustomAttribute.cs @@ -90,6 +90,13 @@ namespace ICSharpCode.Decompiler.TypeSystem.Implementation ); hasDecodeErrors = true; valueDecoded = true; // in case of errors, never try again. + } catch (BadImageFormatException) { + value = new CustomAttributeValue( + ImmutableArray>.Empty, + ImmutableArray>.Empty + ); + hasDecodeErrors = true; + valueDecoded = true; // in case of errors, never try again. } } }