Actually netic it would still work albeit at a reduced efficiency.
Its been over 35 years since I was trained as a naval rating specialising in sonar (UC - Underwater Controllers we were called) so don't ask me for exact figures of speed of sound underwater but in a nutshell all a sonar does is send a concentrated sound wave out from the transducer and listens for it's echo (hence the nickname 'echo sounder'). Our naval systems consisted of a 'segmented/multi directional' transducer while a modern sounder like those we use in our tinnies and so forth are uni-directional and some, (side scanning sonar) have multiple transducers. The direction a single tranducer is pointed is irrelevant. The sonar sends out a pulse, measures the time it takes to receive the echo and mathematically calculates the distance from the object from which the echo came.
There are variables that need to be accounted for such as water temp, inversions (ie cold water layers over warm), backscatter from impurities in the water, salinity, double echoes, sound wave frequency etc but if you send out a pulse say, sideways in a steep rock sided canyon, and receive the echo the sonar will tell you the distance from the transducer to the rock walls but not the depth. Echoes are deflected in ALL directions so while a pulse might hit a solid rock floor at an angle, sufficient reflection of the sound will be received to allow the sonar to work.
Hope this helps explain it. I could tell you heaps of stories about tracking subs, navigating channels etc but "Sea Patrol" is on and I want to finish watching it.