Author: toad
Date: 2008-07-21 11:55:04 +0000 (Mon, 21 Jul 2008)
New Revision: 21279
Modified:
branches/db4o/freenet/src/freenet/node/RequestStarter.java
Log:
Paranoia
Modified: branches/db4o/freenet/src/freenet/node/RequestStarter.java
===================================================================
--- branches/db4o/freenet/src/freenet/node/RequestStarter.java 2008-07-20
21:10:05 UTC (rev 21278)
+++ branches/db4o/freenet/src/freenet/node/RequestStarter.java 2008-07-21
11:55:04 UTC (rev 21279)
@@ -297,6 +297,10 @@
public boolean exclude(RandomGrabArrayItem item, ObjectContainer
container, ClientContext context) {
if(isInsert) return false;
+ if(!(item instanceof BaseSendableGet)) {
+ Logger.error(this, "On a request scheduler, exclude()
called with "+item, new Exception("error"));
+ return false;
+ }
BaseSendableGet get = (BaseSendableGet) item;
if(get.hasValidKeys(sched.fetchingKeys(), container, context))
return false;