#vulnerable code 
                                @Test
    public void testSubset() throws Exception {
        Properties props = new Properties();
        props.load(new FileInputStream("target/test-classes/log4j2-properties.properties"));
        Properties subset = PropertiesUtil.extractSubset(props, "appender.Stdout.filter.marker");
        assertNotNull("No subset returned", subset);
        assertTrue("Incorrect number of items. Expected 4, actual " + subset.size(), subset.size() == 4);
        assertTrue("Missing property", subset.containsKey("type"));
    } 
                            #location 4 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                                @Test
    public void testSubset() throws Exception {
        Properties props = new Properties();
        props.load(ClassLoader.getSystemResourceAsStream("log4j2-properties.properties"));
        Properties subset = PropertiesUtil.extractSubset(props, "appender.Stdout.filter.marker");
        assertNotNull("No subset returned", subset);
        assertTrue("Incorrect number of items. Expected 4, actual " + subset.size(), subset.size() == 4);
        assertTrue("Missing property", subset.containsKey("type"));
    }