--- a/src/internfile/internfile.cpp
+++ b/src/internfile/internfile.cpp
@@ -325,6 +325,7 @@
 
     df->set_docsize(docsize);
     if (!df->set_document_file(m_fn)) {
+	delete df;
 	LOGERR(("FileInterner:: error converting %s\n", m_fn.c_str()));
 	return;
     }