Differences From Artifact [3d72b3b75b]:
- File src/OFXMLParser.m — part of check-in [3af65b5d98] at 2018-06-16 14:21:29 on branch trunk — OFXMLElement: Add a few extra type checks (user: js, size: 24661) [annotate] [blame] [check-ins using]
To Artifact [a92d1baa88]:
- File
src/OFXMLParser.m
— part of check-in
[0ec6f9c1d9]
at
2018-06-16 14:36:35
on branch trunk
— OFXML*: Remember delimiter of attributes
This means that if OFXMLParser parsed double-quoted attributes,
OFXMLElement will emit them with double-quotes again. (user: js, size: 24762) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 | /* Looking for attribute value */ - (void)of_inAttributeValueState { void *pool; OFString *attributeValue; size_t length; if (_data[_i] != _delimiter) return; if ((length = _i - _last) > 0) appendToBuffer(_buffer, _data + _last, _encoding, length); pool = objc_autoreleasePoolPush(); attributeValue = transformString(self, _buffer, 0, true); if (_attributePrefix == nil && [_attributeName isEqual: @"xmlns"]) [[_namespaces lastObject] setObject: attributeValue forKey: @""]; if ([_attributePrefix isEqual: @"xmlns"]) [[_namespaces lastObject] setObject: attributeValue forKey: _attributeName]; | > < | | | > > | 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 | /* Looking for attribute value */ - (void)of_inAttributeValueState { void *pool; OFString *attributeValue; size_t length; OFXMLAttribute *attribute; if (_data[_i] != _delimiter) return; if ((length = _i - _last) > 0) appendToBuffer(_buffer, _data + _last, _encoding, length); pool = objc_autoreleasePoolPush(); attributeValue = transformString(self, _buffer, 0, true); if (_attributePrefix == nil && [_attributeName isEqual: @"xmlns"]) [[_namespaces lastObject] setObject: attributeValue forKey: @""]; if ([_attributePrefix isEqual: @"xmlns"]) [[_namespaces lastObject] setObject: attributeValue forKey: _attributeName]; attribute = [OFXMLAttribute attributeWithName: _attributeName namespace: _attributePrefix stringValue: attributeValue]; attribute->_useDoubleQuotes = (_delimiter == '"'); [_attributes addObject: attribute]; objc_autoreleasePoolPop(pool); [_buffer removeAllItems]; [_attributeName release]; [_attributePrefix release]; _attributeName = _attributePrefix = nil; |
︙ | ︙ |