@@ -0,0 +1,1365 @@
+package sfBugsNew;%0A%0Aimport java.io.File;%0Aimport java.io.FileInputStream;%0Aimport java.io.FileOutputStream;%0Aimport java.io.IOException;%0Aimport java.io.InputStream;%0Aimport java.io.OutputStream;%0A%0Aimport edu.umd.cs.findbugs.annotations.ExpectWarning;%0A%0Apublic class Bug1145 %7B%0A%0A    // Method called to copy files%0A    @ExpectWarning(%22OBL_UNSATISFIED_OBLIGATION_EXCEPTION_EDGE,RV,NP%22)%0A    public static void copyDirectory(File sourceLocation, File targetLocation) throws IOException %7B%0A        if (sourceLocation.isDirectory()) %7B%0A            if (!targetLocation.exists()) %7B%0A                targetLocation.mkdir();%0A            %7D%0A            String%5B%5D children = sourceLocation.list();%0A            for (int i = 0; i %3C children.length; i++) %7B%0A                copyDirectory(new File(sourceLocation, children%5Bi%5D), new File(targetLocation, children%5Bi%5D));%0A            %7D%0A        %7D else %7B%0A            InputStream in = null;%0A            OutputStream out = null;%0A            byte%5B%5D buf = new byte%5B1024%5D;%0A            int len;%0A            try %7B%0A                in = new FileInputStream(sourceLocation);%0A                out = new FileOutputStream(targetLocation);%0A                while ((len = in.read(buf)) %3E 0) %7B%0A                    out.write(buf, 0, len);%0A                %7D%0A            %7D finally %7B%0A                in.close();%0A                out.close();%0A            %7D%0A        %7D%0A    %7D%0A%7D%0A

add test case