fixed bugs for comprehensive test program