#fixed code
                             @Override
	public Expression encode(int index, FieldName name){
		Expression expression = new FieldRef(name);

		if(getWithMean()){
			Number mean = Iterables.get(getMean(), index);

			if(Double.compare(mean.doubleValue(), 0d) != 0){
				expression = PMMLUtil.createApply("-", expression, PMMLUtil.createConstant(mean));
			}
		} // End if

		if(gwtWithStd()){
			Number std = Iterables.get(getStd(), index);

			if(Double.compare(std.doubleValue(), 1d) != 0){
				expression = PMMLUtil.createApply("/", expression, PMMLUtil.createConstant(std));
			}
		}

		// "($name - mean) / std"
		return expression;
	}
#vulnerable code 
                             @Override
	public Expression encode(int index, FieldName name){
		Expression expression = new FieldRef(name);

		if(withMean()){
			Number mean = Iterables.get(getMean(), index);

			if(Double.compare(mean.doubleValue(), 0d) != 0){
				expression = PMMLUtil.createApply("-", expression, PMMLUtil.createConstant(mean));
			}
		} // End if

		if(withStd()){
			Number std = Iterables.get(getStd(), index);

			if(Double.compare(std.doubleValue(), 1d) != 0){
				expression = PMMLUtil.createApply("/", expression, PMMLUtil.createConstant(std));
			}
		}

		// "($name - mean) / std"
		return expression;
	} 
                            #location 5 
                            #vulnerability type NULL_DEREFERENCE