Fix two crashers

Fixes the following two crashes:

==================================
ERROR in ruwiki:Участник:UnCursed:
Cannot read property 'nodeType' of null
Stack trace: TypeError: Cannot read property 'nodeType' of null
    at Object.DOMUtils.isElt (/srv/deployment/parsoid/Parsoid/js/lib/mediawiki.DOMUtils.js:31:14)
    at markFosteredContent (/srv/deployment/parsoid/Parsoid/js/lib/dom.markFosteredContent.js:90:16)
    at markFosteredContent (/srv/deployment/parsoid/Parsoid/js/lib/dom.markFosteredContent.js:124:5)
    at markFosteredContent (/srv/deployment/parsoid/Parsoid/js/lib/dom.markFosteredContent.js:124:5)
    at markFosteredContent (/srv/deployment/parsoid/Parsoid/js/lib/dom.markFosteredContent.js:124:5)
    at Array.markFosteredContent [as 1] (/srv/deployment/parsoid/Parsoid/js/lib/dom.markFosteredContent.js:124:5)
    at DOMPostProcessor.doPostProcess (/srv/deployment/parsoid/Parsoid/js/lib/mediawiki.DOMPostProcessor.js:203:22)
    at EventEmitter.emit (events.js:88:17)
    at FauxHTML5.TreeBuilder.onEnd (/srv/deployment/parsoid/Parsoid/js/lib/mediawiki.HTML5TreeBuilder.node.js:109:7)
    at SyncTokenTransformManager.EventEmitter.emit (events.js:85:17)
==================================
ERROR in enwiki:Wikipedia:WikiProject_Yugoslavia/Sidebar:
INVALID_CHARACTER_ERR (5): the string contains invalid characters
Stack trace: INVALID_CHARACTER_ERR: INVALID_CHARACTER_ERR (5): the string contains invalid characters
    at Object.exports.InvalidCharacterError (/srv/deployment/parsoid/config/node_modules/domino/lib/utils.js:19:52)
    at HTMLMetaElement.setAttribute (/srv/deployment/parsoid/config/node_modules/domino/lib/Element.js:437:40)
    at /srv/deployment/parsoid/Parsoid/js/lib/mediawiki.DOMPostProcessor.js:109:10
    at Array.forEach (native)
    at Object.prepareDOM [as run] (/srv/deployment/parsoid/Parsoid/js/lib/mediawiki.DOMPostProcessor.js:108:15)
    at DOMTraverser.callHandlers (/srv/deployment/parsoid/Parsoid/js/lib/domTraverser.js:38:31)
    at DOMTraverser.traverse (/srv/deployment/parsoid/Parsoid/js/lib/domTraverser.js:83:17)
    at DOMTraverser.traverse (/srv/deployment/parsoid/Parsoid/js/lib/domTraverser.js:94:10)
    at DOMTraverser.traverse (/srv/deployment/parsoid/Parsoid/js/lib/domTraverser.js:94:10)
    at DOMPostProcessor.doPostProcess (/srv/deployment/parsoid/Parsoid/js/lib/mediawiki.DOMPostProcessor.js:203:22)
==================================

Change-Id: I517c7c32a4154c0d59b90f05bbbb803df32fda81