Fix crash in DUChain::addDocumentChain

BUG: 333477