make stat call os aware in check_old_log()