Why do you pass the size of a pointer to snprintf?
Doing so explains why you only get one character written to the array. That and the trailing NULL are all that fit in a "2 element array".
Why do you pass the size of a pointer to snprintf?
Doing so explains why you only get one character written to the array. That and the trailing NULL are all that fit in a "2 element array".