Hakan Calhanoglu's goal spared Milan from a third successive league defeat.