Coffee can sometimes be quite acidic so older cream may curdle in it. The best way to prevent this from happening is to use fresh cream and a lower-acid coffee, and blitz it in a blender right away to make sure the cream disperses through the coffee and the reaction slows down.