Sustain pedal resets itself close to the end locator

Hello! First time posting here. Ive tried to find a solution with different search terms and going through all midi options i could find but couldn’t resolve the issue so i’d like to ask for some help. It most likely an easy solution though so i’d like to apologize in advance.

The Problem: I have a simple piano part. 3 Chords. The sustain pedal is only present via automation (cc64) and is activated somewhere during the chord (max value) and turns off right before the next chord is playing (value 0). Everything works as intended. However, with the loop function turned on, it always turns off the pedal a few moments before the end of the loop is reached. If i move the right locator away, the pedal holds as intended and turns off on the correct spot (which is the moment the line in the automation panel drops to 0). If i move the end locator to another chord, the same problem appears. The value in the automation is still 127 but the pedal is turned off a few moments before the end of the loop is reached.
This tells me that there must be some setting that i cannot find anywhere that might reset automation before the cursor hits the end of the selected part in the timeline. This problem persists with other instruments as well, so its not the instrument that is causing the issue.

I would be thankful for any help to fix this. I can provide images or video if requested, although i don’t think its necessary.

I talked to an audio engineer and he had the same issue. Never bothered him though since the strange behavior does not affect the mixdown. As for me, it is very annoying because it disturbs my personal workflow when writing songs.

There has to be a reason why cuibase does this, and - hopefully - a way to fix it.

Oh, and in case it matters: I am using cubase 8 artist on a win 7 home premium PC, 64 Bit, i7, 16 GB RAM, sapphire pro 40. No other issues to complain about.

I couldn’t reproduce this behaviour. Maybe try extending the notes and leave the pedal out.

Thanks for the reply!
I am not looking for a workaround but hopefully a solution to change cubases behavior. It should be easy to reproduce this issue though, as illustrated below. The only difference between the two scenarios is the end locator of the loop. The end of the loop resets and ignores further automation (including sustain pedal information) close to the end before repeating.

The sustain pedal plays a huge role in my play style. As i understand, cubase does the reset to prevent values from messing up when it jumps to another part of the song. It might be quite useful, however it disturbs my personal workflow and therefore i am looking for an option to turn this feature off, if possible.

[EDIT] Fixed images. I had to scale them to 700 width because of forum limitation so i hope they are still showing what they’re supposed to show.