Skip to content

Commit

Permalink
Prevent timing NPEs on CrawlLimitEnforcer-triggered crawl end
Browse files Browse the repository at this point in the history
* AbstractFrontier.java
    close recovery log in stop() (comes later, usu. from managerThread) rather than terminate() (earlier, may occur in other threads like progress-stats-snapshot thread)
  • Loading branch information
gojomo committed Dec 5, 2009
1 parent 21d4bce commit 7d00618
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,7 @@ public boolean isRunning() {

public void stop() {
terminate();
ArchiveUtils.closeQuietly(this.recover);
}


Expand Down Expand Up @@ -643,8 +644,6 @@ public void unpause() {

synchronized public void terminate() {
requestState(State.FINISH);
// TODO: move this recover-cleanup to manager thread?
ArchiveUtils.closeQuietly(this.recover);
}

/**
Expand Down

0 comments on commit 7d00618

Please sign in to comment.