In case the self-doc was not sent first by the handler, its udi was not recalculated, and it clobbered the last subdoc

This commit is contained in:
Jean-Francois Dockes 2019-06-16 13:46:00 +02:00
parent be214c4a5a
commit e38e58c37a
2 changed files with 6 additions and 2 deletions

View File

@ -318,6 +318,7 @@ class PstExtractor(object):
reader = PFFReader(self.em.rclog, infile=self.filein)
self.generator = reader.mainloop()
ipath = ""
try:
doc, ipath = next(self.generator)
self.em.setmimetype("message/rfc822")
@ -325,7 +326,10 @@ class PstExtractor(object):
except StopIteration:
self.em.rclog("getnext: end of iteration")
return(True, "", "", rclexecm.RclExecM.eofnext)
except Exception as ex:
self.em.rclog("getnext: exception: %s" % ex)
return(False, "", "", rclexecm.RclExecM.eofnow)
return (True, doc, ipath, rclexecm.RclExecM.noteof)

View File

@ -745,8 +745,8 @@ FsIndexer::processonefile(RclConfig *config,
}
} else {
hadNonNullIpath = true;
make_udi(fn, doc.ipath, udi);
}
make_udi(fn, doc.ipath, udi);
// Set file name, mod time and url if not done by
// filter. We used to set the top-level container file