Commit e88b8bd593c765db9190fbdfc0a5583f179ac6c8

Ben Straub 2012-05-01T14:37:11

Incorporating feedback from @tanoku. Removed repeated strlen's, and unnecessary loop-termination variable.