fix log(0)