fix invalid memory read in CEPInferenceMethod class