removed debuging printf functions