Take advantage of c99 to have loop local vars