|
|
|
|
|
by bruce343434
5 days ago
|
|
I'll change your mind: If you pass NULL as the destination pointer, it doesn't write any string. If you combine this with %n at the end of the format string, you can get the exact length that the output string would be. Then you allocate that, then you print again, into the actual destination buffer this time. |
|