I'm constantly haveing this bug and it drives me crazy. Please download the sample project and do those steps:
1. put your playback cursor on red marker (marker no.5)
2. time selection should be from marker 3 adn marker 5
3. run action 41160 (write current values for all active envelopes to time selection)
4. see what happens by yourself
This bug makes that function unreliable, forcing me to double check it every time, in most cases I have to manually fix the problem. Thst's opposite to time saving.
It looks like there's problem with proper generating points on marker when using this action.