This happens to me all the time. I use the Smart Tool. Grab the end of the clip and drag it a bar or tow. I do this on ALL MIDI before bouncing so I get sustain, ring, reverb, etc.
TIP: Your needs may be different, but I highlight all the MIDI clips in a single track and go to Clips | Bounce to Clips before converting to audio so I only have to drag the end of one clip instead of the ends of many small clips.
I first noticed this when freezing a Kontakt instrument bass.