Allow logging of INF and NAN values (fixes #181)