Fix printf to match int type (bug #247)