From the aforementioned site on Diving…
"The human ear is an extremely sensitive pressure detector in air, but it is less efficient in water. A sound must therefore be more intense in water (+20 dB to 60 dB, SPL) to be heard. Hearing under water is very similar to trying to hear with a conductive hearing loss under surface conditions: a smaller shift in pressure is required to hear sounds at the extreme high and low frequencies, because the ear is not as sensitive at these frequencies. "
"Sound is transmitted through water as a series of pressure waves. High intensity sound is transmitted by correspondingly high intensity pressure waves. A diver may be affected by a high intensity pressure wave that is transmitted from the surrounding water to the open spaces within the body (ears, sinuses, lungs). The pressure wave may create increased pressure within these open spaces, which could result in injury.
The sources of high intensity sound or pressure waves include underwater explosions and, in some cases, sonar. Low intensity sonars such as depth finders and fish finders do not produce pressure waves of an intensity dangerous to a diver."
I got the impression that the explosion would need to be larger than a gunshot to be detrimental to your health.