#fixed code
                                @Test
    public void test2() {
        List<String> ftvec1 = Arrays.asList("1:1.0", "2:3.0", "3:3.0");
        List<String> ftvec2 = Arrays.asList("1:2.0", "3:6.0");
        double d = EuclidDistanceUDF.euclidDistance(ftvec1, ftvec2);
        Assert.assertEquals(Math.sqrt(1.0 + 9.0 + 9.0), d, 0.f);
    }
#vulnerable code 
                                @Test
    public void test2() {
        EuclidDistanceUDF udf = new EuclidDistanceUDF();
        List<String> ftvec1 = Arrays.asList("1:1.0", "2:3.0", "3:3.0");
        List<String> ftvec2 = Arrays.asList("1:2.0", "3:6.0");
        FloatWritable d = udf.evaluate(ftvec1, ftvec2);
        Assert.assertEquals((float) Math.sqrt(1.0 + 9.0 + 9.0), d.get(), 0.f);
    } 
                            #location 6 
                            #vulnerability type RESOURCE_LEAK