Fixed bugs in system.out.trace