Bug fix for false meridian flip. This happens, since the calculation of the current HA has a weakness not ensuring that -12 < HA <= 12. For targets with small RA value like M31 a summer night with an LST of 19:00 leads to an uncorrected HA value of approx. 18:45 - which is equivalent to a corrected value of -5:15.
I prefer if we start using the functions in indicom.
They're very useful in KStars.
So just add #include <indicom.h>
deltaHA = rangeHA(deltaHA);