diff --git a/js/ccnxProtocol/modules/ndn-js.jsm b/js/ccnxProtocol/modules/ndn-js.jsm
index f61d93b..32b95f2 100644
--- a/js/ccnxProtocol/modules/ndn-js.jsm
+++ b/js/ccnxProtocol/modules/ndn-js.jsm
@@ -232,8 +232,16 @@
 				// Use readInputStreamToString to handle binary data.
 				this.data += NetUtil.readInputStreamToString(inStream, count);
 				
-				// TODO: Don't know why, but we never receive onStopRequest, assume we have
-				//   all the data and force it now.
+				// TODO: Need to parse the input to check if a whole ccnb object has been read, as in 
+				// CcnbObjectReader class: https://github.com/NDN-Routing/NDNLP/blob/master/ndnld.h#L256 .
+				// For now as a hack, try to fully decode this.data as a ContentObject.
+				try {
+ 					decodeHexContentObject(DataUtils.stringToHex(this.data));
+				} catch (ex) {
+					// Assume the exception is because the decoder only got partial data, so read moe.
+					return;
+				}
+				// We were able to parse the ContentObject, so finish.
 				this.onStopRequest();
 			} catch (ex) {
 				dump("onDataAvailable exception: " + ex + "\n");
@@ -271,7 +279,7 @@
 				if (result == null || result == undefined || result =="" )
 					listener.onReceivedContentObject(null);
 				else {
-					var co = decodeHexContentObject(result);
+ 					var co = decodeHexContentObject(result);
 					
 					if(LOG>2) {
 						dump('DECODED CONTENT OBJECT\n');
@@ -1719,7 +1727,7 @@
 		}
 		this.publisherID = decoder.readBinaryElement(nextTag);
 		if (null == this.publisherID) {
-			throw new Error("Cannot parse publisher ID of type : " + nextTag + ".");
+			throw new ContentDecodingException("Cannot parse publisher ID of type : " + nextTag + ".");
 		}
 };
 
@@ -2006,7 +2014,7 @@
 ForwardingEntry.prototype.from_ccnb =function(
 	//XMLDecoder 
 	decoder) 
-	//throws Error
+	//throws ContentDecodingException
 	{
 			decoder.readStartElement(this.getElementLabel());
 			if (decoder.peekStartElement(CCNProtocolDTags.Action)) {
@@ -2925,7 +2933,7 @@
 				// DKS TODO are attributes same or different dictionary?
 				attributeName = tagToString(thisTV.val());
 				if (null == attributeName) {
-					throw new Error("Unknown DATTR value" + thisTV.val());
+					throw new ContentDecodingException("Unknown DATTR value" + thisTV.val());
 				}
 			}
 			
@@ -2938,7 +2946,7 @@
 
 	} catch ( e) {
 
-		throw new Error("readStartElement", e);
+		throw new ContentDecodingException("readStartElement", e);
 	}
 };
 
@@ -3101,7 +3109,7 @@
 
 			if (tv.type() == XML_TAG) {
 				/*if (tv.val()+1 > DEBUG_MAX_LEN) {
-					throw new Error("Decoding error: length " + tv.val()+1 + " longer than expected maximum length!");
+					throw new ContentDecodingException("Decoding error: length " + tv.val()+1 + " longer than expected maximum length!");
 				}*/
 
 				// Tag value represents length-1 as tags can never be empty.
@@ -3129,7 +3137,7 @@
 			this.offset = previousOffset;
 		} catch ( e) {
 			Log.logStackTrace(Log.FAC_ENCODING, Level.WARNING, e);
-			throw new Error("Cannot reset stream! " + e.getMessage(), e);
+			throw new ContentDecodingException("Cannot reset stream! " + e.getMessage(), e);
 		}
 	}
 	return decodedTag;
@@ -3177,7 +3185,7 @@
 
 				if (tv.type() == XML_TAG) {
 					if (tv.val()+1 > DEBUG_MAX_LEN) {
-						throw new Error("Decoding error: length " + tv.val()+1 + " longer than expected maximum length!");
+						throw new ContentDecodingException("Decoding error: length " + tv.val()+1 + " longer than expected maximum length!");
 					}
 
 					var valval ;
@@ -3248,10 +3256,10 @@
 			
 			if (next != XML_CLOSE) {
 				console.log("Expected end element, got: " + next);
-				throw new Error("Expected end element, got: " + next);
+				throw new ContentDecodingException("Expected end element, got: " + next);
 			}
 		//} catch ( e) {
-			//throw new Error(e);
+			//throw new ContentDecodingException(e);
 		//}
 	};
 
@@ -3305,7 +3313,7 @@
 	//timestamp.setDateBinary(byteTimestamp);
 	
 	if (null == timestamp) {
-		throw new Error("Cannot parse timestamp: " + DataUtils.printHexBytes(byteTimestamp));
+		throw new ContentDecodingException("Cannot parse timestamp: " + DataUtils.printHexBytes(byteTimestamp));
 	}		
 	return timestamp;
 };
@@ -3563,7 +3571,7 @@
 			startTag,
 			//TreeMap<String, String> 
 			attributes) {
-			//throws Error 
+			//throws ContentDecodingException 
 
 		this.readStartElement(startTag, attributes); // can't use getElementText, can't get attributes
 		//String 
