limit itoa output to max N chars