Merge "Fix possible out of bounds read" into mnc-dev