math: fix scalbn and scalbnf on overflow/underflow