#vulnerable code 
                                @Test
    public void testRequestExpectContinueGenerated() throws Exception {
        HttpContext context = new BasicHttpContext(null);
        BasicHttpEntityEnclosingRequest request = new BasicHttpEntityEnclosingRequest("POST", "/");
        String s = "whatever";
        StringEntity entity = new StringEntity(s, "US-ASCII");
        request.setEntity(entity);
        request.getParams().setBooleanParameter(CoreProtocolPNames.USE_EXPECT_CONTINUE, true);
        RequestExpectContinue interceptor = new RequestExpectContinue();
        interceptor.process(request, context);
        Header header = request.getFirstHeader(HTTP.EXPECT_DIRECTIVE);
        Assert.assertNotNull(header);
        Assert.assertEquals(HTTP.EXPECT_CONTINUE, header.getValue());
    } 
                            #location 13 
                            #vulnerability type NULL_DEREFERENCE
#fixed code
                                @Test
    public void testRequestExpectContinueGenerated() throws Exception {
        HttpContext context = new BasicHttpContext(null);
        BasicHttpEntityEnclosingRequest request = new BasicHttpEntityEnclosingRequest("POST", "/");
        String s = "whatever";
        StringEntity entity = new StringEntity(s, "US-ASCII");
        request.setEntity(entity);
        request.getParams().setParameter(CoreProtocolPNames.USE_EXPECT_CONTINUE, true);
        RequestExpectContinue interceptor = new RequestExpectContinue();
        interceptor.process(request, context);
        Header header = request.getFirstHeader(HTTP.EXPECT_DIRECTIVE);
        Assert.assertNotNull(header);
        Assert.assertEquals(HTTP.EXPECT_CONTINUE, header.getValue());
    }