There was no large exit holes so very well may have not hit anything too make it expand .. both bullets were though the bear .. one each way ..
Ok, let me explain, hunting "expanding" bullets are manufactured to expand in a certain velocity range. Below and after that the bullets will not expand.
At 40y it is likely that the 30-06 bullet was too fast to "flower" and since it didn't hit bone,... the bear charged.
Now a 357mag at 40y is withing the expansion of a oft point so it would arguably have been better.