[Mono-devel-list] [PATCH] Default attribute removal in XmlElement
Atsushi Eno
atsushi at ximian.com
Wed Jan 14 03:20:27 EST 2004
Ah, sure you're right. Just fixed and added reproducable test.
Thanks!
Atsushi Eno
Boris Kirzner wrote:
> No
> The previous Specified fix takes care about default attributes loading
> for the firs time.
> The whole (I hope) resolution of an issue is box fixes applied.
> This (the second one) also takes care about removal (and immediate
> restore) of attributes that have default values.
>
> Thank you
>
> Boris Kirzner
>
> Atsushi Eno wrote:
>
>> It looks fixed with the previous "Specified" fix...?
>>
>> Atsushi Eno
>>
>> Boris Kirzner wrote:
>>
>>> Description of Problem:
>>> - If the removed attribute is known to have a default value, an
>>> attribute should immediately appear containing the default value.
>>> - Re-setting an attribute to its default value requires that the
>>> attribute be deleted. New attribute with its Specified property set
>>> to False should be created.
>>>
>>> Steps to reproduce the problem :
>>> 1. Create DTD file defining some node having default attribute value.
>>> 2. Create XML file referencing the DTD, with node inside that
>>> attribute value having default in DTD is not explicitly specified.
>>> 3. Load XML document into XmlDocument
>>> 4. Remove the attribute
>>> 4. Inspect Value and Specified properties of the attribute.
>>>
>>> Actual result :
>>> System.NullReferenceException: A null value was found where an object
>>> instance was required in <0x00128>
>>>
>>> Expected result :
>>> Yes
>>> False
>>>
>>> Enclosed is a small test case and a patch.
>>>
>>> Thank you in advance,
>>>
>>> Boris Kirzner
>>
>>
>>
>>
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
>
More information about the Mono-devel-list
mailing list