#vulnerable code 
                             protected byte[] loadRes(String filename) {
		try {
			URL res = resource(filename);
			return res != null ? readBytes(new FileInputStream(new File(res.getFile()))) : null;
		} catch (FileNotFoundException e) {
			throw new RuntimeException(e);
		}
	} 
                            #location 4 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                             protected byte[] loadRes(String filename) {
		InputStream input = TestCommons.class.getClassLoader().getResourceAsStream(filename);
		return input != null ? readBytes(input) : null;
	}