diff --git a/findbugs/src/java/edu/umd/cs/findbugs/ba/obl/ObligationSet.java b/findbugs/src/java/edu/umd/cs/findbugs/ba/obl/ObligationSet.java
index <HASH>..<HASH> 100644
--- a/findbugs/src/java/edu/umd/cs/findbugs/ba/obl/ObligationSet.java
+++ b/findbugs/src/java/edu/umd/cs/findbugs/ba/obl/ObligationSet.java
@@ -53,8 +53,18 @@ public class ObligationSet {
 
 	public void remove(Obligation obligation) throws NonexistentObligationException {
 		short count = countList[obligation.getId()];
-		if (count <= 0)
-			throw new NonexistentObligationException(obligation);
+		
+		// It is possible to remove a nonexistent obligation.
+		// Generally this indicates buggy code, e.g.
+		//     InputStream in = null;
+		//     try {
+		//       in = new FileInputStream(...);
+		//     } catch (IOException e) {
+		//        in.close(); // in might be null!
+		//     }
+//		if (count <= 0)
+//			throw new NonexistentObligationException(obligation);
+		
 		invalidate();
 		countList[obligation.getId()] = (short)(count - 1);
 	}
Don't throw exception indicating that a nonexistent obligation is
being removed.  This can arise, possibly because of buggy code
that tries to close a resource that has not been opened.


git-svn-id: <URL>