Author: toad
Date: 2007-03-27 16:29:56 +0000 (Tue, 27 Mar 2007)
New Revision: 12387

Modified:
   trunk/freenet/src/freenet/client/async/SingleBlockInserter.java
Log:
NPE on creation rather than later

Modified: trunk/freenet/src/freenet/client/async/SingleBlockInserter.java
===================================================================
--- trunk/freenet/src/freenet/client/async/SingleBlockInserter.java     
2007-03-27 16:04:12 UTC (rev 12386)
+++ trunk/freenet/src/freenet/client/async/SingleBlockInserter.java     
2007-03-27 16:29:56 UTC (rev 12387)
@@ -64,6 +64,7 @@
                this.uri = uri;
                this.compressionCodec = compressionCodec;
                this.sourceData = data;
+               if(sourceData == null) throw new NullPointerException();
                this.isMetadata = isMetadata;
                this.sourceLength = sourceLength;
                this.getCHKOnly = getCHKOnly;


Reply via email to