#vulnerable code 
                                Element pop() {
        // todo - dev, remove validation check
        if (stack.peekLast().nodeName().equals("td") && !state.name().equals("InCell"))
            Validate.isFalse(true, "pop td not in cell");
        if (stack.peekLast().nodeName().equals("html"))
            Validate.isFalse(true, "popping html!");
        return stack.pollLast();
    } 
                            #location 3 
                            #vulnerability type NULL_DEREFERENCE
#fixed code
                                HtmlTreeBuilder() {}