fixed inf loop vuln, added some comments