-179.9 and 180.1 are the same angle. So the angle isn't "incorrect" in any meaningful way. If the point is that it should be 179.9 and not 180.1, you need to make your code more robust.
Again, if you use quaternions during the interpolation, many problems will go away.