This event seems to be a little bit random:
As the crew made their way to the cave entrance to the Fountain of Youth, Salaman breaks a piece of stalactite off, which caused another stalactite to fall onto a pirate near him, killing him instantly.
However the idea of the Fountain of youth is that "eternal life" is not free. The whole premise is in order to gain something, you need to take it from somewhere else:
Legends tell that eternal life could be found at the Fountain of Youth, but only those who possess the knowledge of the ritual of the Fountain could achieve it. The two silver Chalices of Cartagena were needed, for the ritual required not just a seeker of youth but also a victim whose years would be consumed. Only a mermaid's tear, placed in one of the Chalices, would set the rejuvenating forces of the Fountain to work. After both drinkers drunk from the Chalices, the Fountain would give the seeker all the years of life from the victim.
So the idea of this whole venture is that life is a fragile thing.
[Gibbs] "Jack, I have to ask. You had the Chalices, the water, the tear. You could've lived, maybe, forever."
[Jack] "The Fountain does test you, Gibbs. But better to not know which moment may be your last, every morsel of your entire being alive to the infinite mystery of it all. And who's to say I won't live forever, eh? Discoverer of the Fountain of Youth."
All in all, this was little more than a bit of dark humour - you shouldn't go messing with ancient magics. It's dangerous.