fixed errorlog()