Studio One is doing the same thing for me: When "Monitor" is enabled, the Automation of the Sustain is recorded incorrectly (turns "off" prematurely). But when Monitor is disabled (so you cannot hear the instrument being played), Studio One's Automation of the Sustain records perfectly.
This is a serious bug. Please fix it.