Fix oops in DataContractJsonSerializer fix
authorAlexis Christoforides <alexis@thenull.net>
Thu, 9 Oct 2014 05:04:34 +0000 (22:04 -0700)
committerAlexis Christoforides <alexis@thenull.net>
Thu, 9 Oct 2014 05:04:34 +0000 (22:04 -0700)
mcs/class/System.ServiceModel.Web/System.Runtime.Serialization.Json/DataContractJsonSerializer.cs
mcs/class/System.ServiceModel.Web/System.Runtime.Serialization.Json/JsonSerializationReader.cs

index 8bb11605edff2177a61bb6bf05ea786ae54ddd6b..8ae0ce57356002636911dc5d32c903933703483b 100644 (file)
@@ -87,7 +87,7 @@ namespace System.Runtime.Serialization.Json
 
                        var knownTypesFromAttributes = new List<Type> ();
 
-                       foreach (var attr in type.GetCustomAttributes (typeof(KnownTypeAttribute)))
+                       foreach (var attr in type.GetCustomAttributes (typeof (KnownTypeAttribute), false))
                                knownTypesFromAttributes.Add ((attr as KnownTypeAttribute).Type);
 
                        if (knownTypes != null)
index 9af14a6cfd5515af78670e7273e1e0cd30f9bafc..d0f84d0f93a6a66ee3a5cb41bc97ce2a14371a38 100644 (file)
@@ -221,7 +221,7 @@ namespace System.Runtime.Serialization.Json
                                                return t;
 
                        if (baseType != null)
-                               foreach (var attr in baseType.GetCustomAttributes (typeof(KnownTypeAttribute)))
+                               foreach (var attr in baseType.GetCustomAttributes (typeof (KnownTypeAttribute), false))
                                        if ((attr as KnownTypeAttribute).Type.FullName.Equals (properName))
                                                return (attr as KnownTypeAttribute).Type;