fix for citation index generation in case that entry.referrerhash() is

null. This is especially the case if ftp sites are crawled
This commit is contained in:
Michael Peter Christen 2013-07-08 16:26:11 +02:00
parent a2c8116a8f
commit a34e137e27

View File

@ -138,7 +138,7 @@ public final class CrawlStacker {
// record the link graph for this request
byte[] anchorhash = entry.url().hash();
IndexCell<CitationReference> urlCitationIndex = this.indexSegment.urlCitation();
if (urlCitationIndex != null) try {
if (urlCitationIndex != null && entry.referrerhash() != null) try {
urlCitationIndex.add(anchorhash, new CitationReference(entry.referrerhash(), entry.appdate().getTime()));
} catch (final Exception e) {
Log.logException(e);