Skip to content

Commit 3ddeaad

Browse files
Add case within name setter for DTDKind
Force set the name for XMLNodes when they're XMLDTDs as the regular _CFXMLNodeSetName function doesn't account for them anymore
1 parent ae61520 commit 3ddeaad

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Sources/FoundationXML/XMLNode.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -357,6 +357,8 @@ open class XMLNode: NSObject, NSCopying {
357357
_CFXMLNodeForceSetName(_xmlNode, newValue)
358358
case .namespace:
359359
_CFXMLNamespaceSetPrefix(_xmlNode, newValue, Int64(newValue?.utf8.count ?? 0))
360+
case .DTDKind:
361+
_CFXMLNodeForceSetName(_xmlNode, newValue)
360362
default:
361363
if let newName = newValue {
362364
_CFXMLNodeSetName(_xmlNode, newName)

0 commit comments

Comments
 (0)