bug fixes (log,out,spc, will not be removed anymore)