#vulnerable code 
                                @Test
    public void shouldLoadURLFromSpecifiedSource() throws IOException {
        final URL[] lastURL = { null };
        ConfigURLStreamHandler handler = new ConfigURLStreamHandler(SampleConfigWithSource.class.getClassLoader(),
                new SystemVariablesExpander()) {
            @Override
            protected URLConnection openConnection(URL url) throws IOException {
                lastURL[0] = url;
                return super.openConnection(url);
            }
        };

        ConfigFactory.getStreamFor(SampleConfigWithSource.class, handler);
        URL expected = new URL(null, "classpath:org/aeonbits/owner/FooBar.properties",
                handler);
        assertEquals(expected, lastURL[0]);
    } 
                            #location 13 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                                @Test
    public void shouldLoadURLFromSpecifiedSource() throws IOException {
        final URL[] lastURL = { null };
        ConfigURLStreamHandler handler = new ConfigURLStreamHandler(SampleConfigWithSource.class.getClassLoader(),
                new SystemVariablesExpander()) {
            @Override
            protected URLConnection openConnection(URL url) throws IOException {
                lastURL[0] = url;
                return super.openConnection(url);
            }
        };

        ConfigFactory.getPropertiesFor(SampleConfigWithSource.class, handler);
        URL expected = new URL(null, "classpath:org/aeonbits/owner/FooBar.properties",
                handler);
        assertEquals(expected, lastURL[0]);
    }